mirror of
https://gitlab.dit.htwk-leipzig.de/htwk-software/htwkalender-pwa.git
synced 2025-07-16 09:38:51 +02:00
fix:#00 always restart containers and change rules of oci build jobs
This commit is contained in:
@ -103,6 +103,8 @@ build-backend-image:
|
||||
- docker push $CI_DOCKER_REGISTRY_REPO:backend
|
||||
rules:
|
||||
- if: $CI_COMMIT_BRANCH == "main"
|
||||
changes:
|
||||
- backend/**/*
|
||||
|
||||
build-frontend-image:
|
||||
stage: oci-build
|
||||
@ -124,6 +126,8 @@ build-frontend-image:
|
||||
- docker push $CI_DOCKER_REGISTRY_REPO:frontend
|
||||
rules:
|
||||
- if: $CI_COMMIT_BRANCH == "main"
|
||||
changes:
|
||||
- frontend/**/*
|
||||
|
||||
deploy-all:
|
||||
stage: deploy
|
||||
@ -145,8 +149,5 @@ deploy-all:
|
||||
"cd /home/$CI_SSH_USER/docker/htwkalender/ &&
|
||||
docker login -u $CI_DOCKER_REGISTRY_USER -p $CI_DOCKER_REGISTRY_PASSWORD $CI_DOCKER_REGISTRY &&
|
||||
docker compose -f ./docker-compose.prod.yml down && docker compose -f ./docker-compose.prod.yml up -d --remove-orphans && docker logout"
|
||||
needs:
|
||||
- build-frontend-image
|
||||
- build-backend-image
|
||||
rules:
|
||||
- if: $CI_COMMIT_BRANCH == "main"
|
||||
|
Reference in New Issue
Block a user