Skip to content

feat(deploy): deploy main to the server automatically after CI passes - #13

Merged
AESMatias merged 1 commit into
mainfrom
feat/project-skeleton
Sep 25, 2026
Merged

AESMatias merged 1 commit into
mainfrom
feat/project-skeleton

Conversation

@AESMatias

Copy link
Copy Markdown
Owner

Add deploy/deploy.sh: it pulls main, builds while the old version keeps serving, restarts the containers and waits for their health checks. If the new version is not healthy within four minutes it restores the previous images and commit by itself; a failed build restarts nothing. One deploy runs at a time.

A new deploy job in CI runs the script over SSH on every push to main whose backend and frontend checks pass. It stays skipped until the DEPLOY_HOST variable is set. The SSH key is pinned in authorized_keys to the deploy script, and the server's host key is verified.

Add deploy/deploy.sh: it pulls main, builds while the old version keeps
serving, restarts the containers and waits for their health checks.
If the new version is not healthy within four minutes it restores the
previous images and commit by itself; a failed build restarts nothing.
One deploy runs at a time.

A new deploy job in CI runs the script over SSH on every push to main
whose backend and frontend checks pass. It stays skipped until the
DEPLOY_HOST variable is set. The SSH key is pinned in authorized_keys
to the deploy script, and the server's host key is verified.
@AESMatias
AESMatias merged commit 0677bb3 into main Sep 25, 2026
4 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant