Phase 6.3: Plan-on-PR Pipeline
Goal: PRs to pal-e-platform show
tofu plan output as a Forgejo PR comment, so reviewers can see exactly what infrastructure changes a PR will make before merge.Owner: Dev agent
Repo:
forgejo_admin/pal-e-platformDepends on: phase-pal-e-platform-ci-6-2-validation-pipeline (COMPLETED)
Scope
- Add 17 Woodpecker repo secrets: KUBECONFIG_CONTENT, FORGEJO_TOKEN, 15 TF_VAR_* secrets
- Update
.woodpecker.yaml: addplanstep that runstofu plan -no-coloron PR events - Plan step runs AFTER validate step (validate gates plan)
- Post plan output as Forgejo PR comment via curl to Forgejo API
- Use modified kubeconfig (server: 10.0.0.217:6443) for in-cluster access from CI pods
Deliverables
- PR #50 merged (squash) —
.woodpecker.yamlupdated with plan step - 17 Woodpecker repo secrets created via API (repo ID 29)
- Pipeline #9 verified: clone→validate→plan all green, plan output posted as 5,520-char PR comment
- Forgejo Issue #48 closed
Bugs Fixed During Implementation
- Woodpecker v3 removed
secrets:step property — migrated toenvironment: ... from_secret: - Forgejo API uses
issues/{N}/commentsnotpulls/{N}/commentsfor PR comments - Woodpecker API requires numeric repo ID (not full name) for secret creation
Related
plan-pal-e-platform-- parent planphase-pal-e-platform-ci-6-4-apply-on-merge-- next phase (depends on this)