Skip to content
Snippets Groups Projects
Commit 6210566b authored by Yannis Barlas's avatar Yannis Barlas
Browse files

Update file .gitlab-ci.yml

parent 066cd1b3
No related branches found
No related tags found
No related merge requests found
Pipeline #61112 failed
variables: # include:
IMAGE_NAME_DEPLOY: wax-demo # - project: 'cokoapps/ci'
# ref: main
# file: 'ci-templates.yml'
include: variables:
- project: 'cokoapps/ci' IMAGE_NAME_DEMO: $CI_REGISTRY/wax/wax-prosemirror/wax-demo
ref: main BUILD_PATH: .
file: 'ci-templates.yml'
stages: stages:
- Build demo - Build demo
- Deploy demo - Deploy demo
build demo image: .build demo:
stage: Build demo
image: docker:26
services:
- docker:26-dind
before_script:
- echo "$CI_REGISTRY_PASSWORD" | docker login "$CI_REGISTRY" -u "$CI_REGISTRY_USER" --password-stdin
script:
- docker pull $IMAGE_NAME_DEMO:latest || true
- docker build
--cache-from $IMAGE_NAME_DEMO:latest
--tag $IMAGE_NAME_DEMO:$CI_COMMIT_SHA
--tag $IMAGE_NAME_DEMO:latest
-f $BUILD_PATH/Dockerfile-production
$BUILD_PATH
- docker push $IMAGE_NAME_DEMO:$CI_COMMIT_SHA
- docker push $IMAGE_NAME_DEMO:latest
.build demo image:
extends: .build production extends: .build production
stage: Build demo stage: Build demo
variables: variables:
...@@ -19,7 +38,7 @@ build demo image: ...@@ -19,7 +38,7 @@ build demo image:
only: only:
- master - master
deploy demo: .deploy demo:
extends: .deploy extends: .deploy
stage: Deploy demo stage: Deploy demo
only: only:
......
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment