Feature: Deploy stacks automatically on merge #17

Merged
claude-bot Bot merged 2 commits from feature/deploy-stacks-on-merge into main 2026-11-27 21:44:55 +01:00

The Deploy Stacks workflow now also runs on a push to main, so merging a stack change deploys it. Before, every deploy had to be started by hand.

The push trigger is limited to paths that affect a deploy: stacks/, the docker_stack role, the stacks playbook, the inventory, the collection requirements and the workflow file itself. Docs and .claude/ changes don't deploy. The manual trigger stays.

Gitea, its runner and Postgres are not in playbooks/docker_stacks.yml, so they still never auto-deploy.

CLAUDE.md and the /merge skill are updated to say that merging now deploys.

Merging this PR runs one deploy of it-tools, which should report no changes.

The Deploy Stacks workflow now also runs on a push to `main`, so merging a stack change deploys it. Before, every deploy had to be started by hand. The push trigger is limited to paths that affect a deploy: `stacks/`, the `docker_stack` role, the stacks playbook, the inventory, the collection requirements and the workflow file itself. Docs and `.claude/` changes don't deploy. The manual trigger stays. Gitea, its runner and Postgres are not in `playbooks/docker_stacks.yml`, so they still never auto-deploy. `CLAUDE.md` and the `/merge` skill are updated to say that merging now deploys. Merging this PR runs one deploy of it-tools, which should report no changes.
claude-bot Bot added 2 commits 2026-11-27 21:43:17 +01:00
docs: note that merging a stack change deploys it
Checks / Secret Scan (pull_request) Successful in 5s
Checks / Lint (pull_request) Successful in 21s
4852971991

Review

Effort: medium

  • .gitea/workflows/deploy-stacks.yaml:5: nothing runs --check --diff against the merged change before the push deploy. The planned PR dry-run job doesn't exist yet. Pre-existing.
  • roles/docker_stack/tasks/main.yml:22: no health check or wait after docker_compose_v2, so a crash-looping container still gives a green deploy. Deploy-on-merge makes this the only signal. Pre-existing.
  • .gitea/workflows/deploy-stacks.yaml:9: "Gitea, runner and Postgres never auto-deploy" now depends on keeping them out of playbooks/docker_stacks.yml. That holds today. A separate playbook or tag would enforce it. Nit.
  • .gitea/workflows/deploy-stacks.yaml:16: no concurrency group. Only safe while the ansible runner's capacity is 1 (the default). Nit.
  • .gitea/workflows/deploy-stacks.yaml:8: ansible.cfg is missing from the path filter. Nit.
  • .claude/skills/merge/SKILL.md:108: the report says "deployed" based on paths alone. It doesn't wait for the push-triggered run's result. Nit.
  • .claude/skills/merge/SKILL.md:111: "Do not ... change a live system" now conflicts with the merge step deploying. Nit.
  • CLAUDE.md:45: the merge prompt doesn't show whether a PR deploys. The user chose this explicitly. Nit.
<!-- claude-review: pass 48529719916505ae6df2a463b1040fc390f2bcbd --> ## Review Effort: medium - `.gitea/workflows/deploy-stacks.yaml:5`: nothing runs `--check --diff` against the merged change before the push deploy. The planned PR dry-run job doesn't exist yet. Pre-existing. - `roles/docker_stack/tasks/main.yml:22`: no health check or `wait` after `docker_compose_v2`, so a crash-looping container still gives a green deploy. Deploy-on-merge makes this the only signal. Pre-existing. - `.gitea/workflows/deploy-stacks.yaml:9`: "Gitea, runner and Postgres never auto-deploy" now depends on keeping them out of `playbooks/docker_stacks.yml`. That holds today. A separate playbook or tag would enforce it. Nit. - `.gitea/workflows/deploy-stacks.yaml:16`: no `concurrency` group. Only safe while the `ansible` runner's capacity is 1 (the default). Nit. - `.gitea/workflows/deploy-stacks.yaml:8`: `ansible.cfg` is missing from the path filter. Nit. - `.claude/skills/merge/SKILL.md:108`: the report says "deployed" based on paths alone. It doesn't wait for the push-triggered run's result. Nit. - `.claude/skills/merge/SKILL.md:111`: "Do not ... change a live system" now conflicts with the merge step deploying. Nit. - `CLAUDE.md:45`: the merge prompt doesn't show whether a PR deploys. The user chose this explicitly. Nit.
claude-bot Bot merged commit 90324a0501 into main 2026-11-27 21:44:55 +01:00
Sign in to join this conversation.
No Reviewers
1 Participants
Notifications
Due Date
No due date set.
Dependencies

No dependencies set.

Reference: kasun/homelab-ansible#17