login + pull :main + --resolve-image always so prod-stack picks up the latest images

Previously a devops push would re-deploy prod-stack against whatever
:main was cached locally on the host, silently reverting recent
frontend/api rolls.

Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
This commit is contained in:
Felix FaerberandClaude Opus 4.7 committed 2026-05-27 14:57:15 +03:00
1 parent 2f4b4d09fa
commit 33e0b4a85b
1 file changed
+5 -2
+5 -2
View File
@@ -18,8 +18,11 @@ jobs:
key: ${{ secrets.SSH_PRIV_KEY }} key: ${{ secrets.SSH_PRIV_KEY }}
script: | script: |
cd ~/devops && git pull cd ~/devops && git pull
docker stack deploy -c ~/devops/hostinger/system-stack.yaml system --with-registry-auth echo ${{ secrets.GITHUB_TOKEN }} | docker login ghcr.io -u ${{ github.actor }} --password-stdin
docker stack deploy -c ~/devops/hostinger/prod-stack.yaml prod --with-registry-auth docker pull ghcr.io/token-for-token/hosted-gateway:main
docker pull ghcr.io/token-for-token/hosted-gateway-frontend:main
docker stack deploy -c ~/devops/hostinger/system-stack.yaml system --with-registry-auth --resolve-image always
docker stack deploy -c ~/devops/hostinger/prod-stack.yaml prod --with-registry-auth --resolve-image always
- name: prune old images - name: prune old images
uses: appleboy/ssh-action@v1.0.3 uses: appleboy/ssh-action@v1.0.3