add registry setup

This commit is contained in:
root
2026-06-02 13:51:06 -04:00
parent e9dfbeb591
commit da1841e6b9
8 changed files with 155 additions and 29 deletions
+6 -6
View File
@@ -108,9 +108,9 @@ build_image:
- docker push $DOCKER_IMAGE
- docker push $DOCKER_IMAGE_LATEST
rules:
# Skip the container publish step unless either the GitLab registry or an
# explicit fallback registry configuration is available.
- if: '$CI_COMMIT_BRANCH == $CI_DEFAULT_BRANCH && (($CI_REGISTRY && $CI_REGISTRY_USER && $CI_REGISTRY_PASSWORD && $CI_REGISTRY_IMAGE) || ($REGISTRY_HOST && $REGISTRY_USER && $REGISTRY_PASSWORD && $REGISTRY_IMAGE))'
# On the default branch, always attempt the image build so missing registry
# configuration fails loudly in before_script instead of skipping the job.
- if: '$CI_COMMIT_BRANCH == $CI_DEFAULT_BRANCH'
- when: never
# ====================================
@@ -147,10 +147,10 @@ deploy_to_vps:
echo "-- Syncing deployment assets --"
ssh $VPS_USER@$VPS_IP "
set -e
mkdir -p '$DEPLOY_ROOT/scripts' '$DEPLOY_ROOT/docker/pgmanage'
mkdir -p '$DEPLOY_ROOT/scripts' '$DEPLOY_ROOT/docker/pgmanage' '$DEPLOY_ROOT/docker/registry/auth'
"
scp docker-compose.production.yml docker-compose.portainer.production.yml traefik.yaml $VPS_USER@$VPS_IP:$DEPLOY_ROOT/
scp scripts/docker-prod-common.sh scripts/docker-prod-deploy.sh $VPS_USER@$VPS_IP:$DEPLOY_ROOT/scripts/
scp docker-compose.production.yml docker-compose.portainer.production.yml docker-compose.registry.production.yml traefik.yaml $VPS_USER@$VPS_IP:$DEPLOY_ROOT/
scp scripts/docker-prod-common.sh scripts/docker-prod-deploy.sh scripts/docker-prod-up-registry.sh $VPS_USER@$VPS_IP:$DEPLOY_ROOT/scripts/
scp docker/pgmanage/override.py $VPS_USER@$VPS_IP:$DEPLOY_ROOT/docker/pgmanage/
echo "-- Running deploy script on VPS --"