AEG-X-004: deploy DbUp migrations with release artifact
ci / backend (push) Failing after 1s
ci / static (push) Failing after 8s
ci / backend (pull_request) Failing after 2s
ci / static (pull_request) Failing after 11s
Build & Test with Secrets / build (pull_request) Failing after 1s
ci / publish (push) Has been cancelled
ci / frontend (push) Has been cancelled
ci / frontend (pull_request) Has been cancelled
ci / publish (pull_request) Has been cancelled
Build & Test with Secrets / security-scan (pull_request) Failing after 8s
Build & Test with Secrets / frontend (pull_request) Successful in 4m42s
Build & Test with Secrets / notification (pull_request) Failing after 1s

This commit is contained in:
2026-08-06 14:46:01 +09:00
parent 1de41b5055
commit 30f4858a34
+14 -10
View File
@@ -30,6 +30,9 @@ jobs:
run: | run: |
dotnet publish -c Release -o ./publish src/KArtSell.Host dotnet publish -c Release -o ./publish src/KArtSell.Host
dotnet publish -c Release -o ./publish src/KArtSell.DbMigrator dotnet publish -c Release -o ./publish src/KArtSell.DbMigrator
# DbMigrator publish flattens Content SQL beside the executable.
# Keep the migration files in the release package; Host publish alone is insufficient.
test -f ./publish/0032_shadow_run_queued_status_contract.sql
- name: Create deployment package - name: Create deployment package
run: | run: |
@@ -53,16 +56,17 @@ jobs:
echo "✅ File transferred" echo "✅ File transferred"
echo "" echo ""
echo "📋 Next steps on server (run these):" ssh -i /tmp/deploy_key.pem -o StrictHostKeyChecking=no kjh2064@178.104.200.7 \
echo " ssh kjh2064@178.104.200.7" "export KARTSELL_POSTGRES='${{ secrets.KARTSELL_POSTGRES }}'; \
echo " sudo rm -rf /app/kartsell/current" sudo mkdir -p /app/kartsell/current; \
echo " sudo mkdir -p /app/kartsell" sudo unzip -oq /tmp/kartsell-release.zip -d /app/kartsell/current; \
echo " cd /app/kartsell && sudo unzip /tmp/kartsell-release.zip" cd /app/kartsell/current; \
echo " export KARTSELL_POSTGRES='${{ secrets.KARTSELL_POSTGRES }}'" dotnet KArtSell.DbMigrator.dll; \
echo " dotnet KArtSell.DbMigrator.dll" sudo systemctl restart kartsell; \
echo " sudo systemctl restart kartsell" sleep 3; \
echo "" systemctl is-active --quiet kartsell"
echo "✅ Deployment package ready"
echo "✅ Artifact deployed, DbMigrator executed, and kartsell restarted"
# Cleanup # Cleanup
rm /tmp/deploy_key.pem rm /tmp/deploy_key.pem