Deploy on any branch push, not just main
Some checks failed
Build and Deploy / build-and-deploy (push) Failing after 43s
Some checks failed
Build and Deploy / build-and-deploy (push) Failing after 43s
Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
This commit is contained in:
@@ -2,7 +2,6 @@ name: Build and Deploy
|
||||
|
||||
on:
|
||||
push:
|
||||
branches: [main]
|
||||
|
||||
env:
|
||||
REGISTRY: registry.rose-ash.com:5000
|
||||
@@ -33,9 +32,11 @@ jobs:
|
||||
DEPLOY_HOST: ${{ secrets.DEPLOY_HOST }}
|
||||
run: |
|
||||
ssh "root@$DEPLOY_HOST" "
|
||||
BRANCH="${GITHUB_REF##refs/heads/}"
|
||||
cd /root/art-dag/celery
|
||||
git fetch origin main
|
||||
git reset --hard origin/main
|
||||
git fetch origin "$BRANCH"
|
||||
git checkout "$BRANCH"
|
||||
git reset --hard "origin/$BRANCH"
|
||||
"
|
||||
|
||||
- name: Build and push image
|
||||
|
||||
Reference in New Issue
Block a user