diff --git a/.gitlab-ci.yml b/.gitlab-ci.yml index 244b92a..20c94fe 100644 --- a/.gitlab-ci.yml +++ b/.gitlab-ci.yml @@ -3,22 +3,36 @@ variables: DOCKER_HOST: tcp://docker:2375 stages: + - pages - build - deploy -build: - stage: build - image: - name: amazon/aws-cli - entrypoint: [""] - services: - - docker:dind - before_script: - - amazon-linux-extras install docker +pages: + stage: pages + cache: + paths: + - node_modules/ script: | - docker build -t $DOCKER_REGISTRY/$REPOSITORY_NAME:$CI_PIPELINE_ID -t $DOCKER_REGISTRY/$REPOSITORY_NAME:latest . - aws ecr get-login-password | docker login --username AWS --password-stdin $DOCKER_REGISTRY - docker push $DOCKER_REGISTRY/$REPOSITORY_NAME --all-tags + npm install + npm run build + mkdir public + cp -R .vitepress/dist/* public + artifacts: + paths: + - public +# build: +# stage: build +# image: +# name: amazon/aws-cli +# entrypoint: [""] +# services: +# - docker:dind +# before_script: +# - amazon-linux-extras install docker +# script: | +# docker build -t $DOCKER_REGISTRY/$REPOSITORY_NAME:$CI_PIPELINE_ID -t $DOCKER_REGISTRY/$REPOSITORY_NAME:latest . +# aws ecr get-login-password | docker login --username AWS --password-stdin $DOCKER_REGISTRY +# docker push $DOCKER_REGISTRY/$REPOSITORY_NAME --all-tags # variables: # SERVICE_NAME: "docs"