Merge pull request #16 from feature/state-corp-dev-migrate-ci-user
All checks were successful
Deploy Customer Main / Build, Push, Deploy (push) Successful in 31s
CI/CD Pipeline / Code Quality Checks (push) Successful in 2m16s
CI/CD Pipeline / Run Tests (push) Successful in 4m4s
CI/CD Pipeline / Build and Push Dev Images (push) Has been skipped
CI/CD Pipeline / Deploy Dev via Compose (push) Has been skipped

Run the dev migration command as the deploy SSH user.
This commit was merged in pull request #16.
This commit is contained in:
avm
2026-07-24 13:26:07 +03:00

View File

@@ -235,4 +235,4 @@ jobs:
EOF
scp -i ~/.ssh/ecos_deploy_key "${tmp_current}.new" "${DEPLOY_USER}@${DEPLOY_HOST}:/tmp/current.env"
ssh -i ~/.ssh/ecos_deploy_key "${DEPLOY_USER}@${DEPLOY_HOST}" 'cat /tmp/current.env > /opt/ecos-dev/releases/current.env && rm -f /tmp/current.env && /opt/ecos-dev/deploy.sh state-corp-backend'
ssh -i ~/.ssh/ecos_deploy_key "${DEPLOY_USER}@${DEPLOY_HOST}" 'cd /opt/ecos-dev && runuser -u ecos-deploy -- docker compose --env-file runtime.env --env-file releases/current.env -f compose.yml run --rm --no-deps state-corp-web python src/manage.py migrate --noinput'
ssh -i ~/.ssh/ecos_deploy_key "${DEPLOY_USER}@${DEPLOY_HOST}" 'cd /opt/ecos-dev && docker compose --env-file runtime.env --env-file releases/current.env -f compose.yml run --rm --no-deps state-corp-web python src/manage.py migrate --noinput'