Repository navigation
Closed
Labels
area:ciCI/CD, GitHub Actions, workflowsarea:workflowDeveloper workflow, commands, rules, skillsbugSomething isn't workingeffort:smallLess than 1 hoursemver:patchBug fix, backward-compatible
Description
Description
Copilot comments on downstream smoke-test PR #43 highlighted workflow risks. Re-evaluating against the current local downstream-dispatch implementation shows several issues are still valid and actionable.
Primary risk areas:
- Container jobs running
gitwithoutsafe.directory - Reusable workflow permission ceilings causing token scope mismatches
- Rollback job container image depending on
coreoutputs that may not exist on early failure - Stale dispatch workflow documentation referencing removed workflows
Steps to Reproduce
- Trigger smoke-test downstream orchestration via
repository_dispatch. - Trigger release workflows through
assets/smoke-test/.github/workflows/repository-dispatch.yml. - Exercise failure paths where
corecan fail before producing outputs. - Observe potential failures in rollback startup, permission-scoped
ghcalls, or git operations in containerized jobs.
Expected Behavior
Downstream release/sync workflows execute reliably in containerized jobs, reusable workflows have sufficient minimal permissions, rollback always starts on failure, and dispatch workflow comments match actual workflow set.
Actual Behavior
Current workflow definitions still contain reliability gaps and drift:
- Missing
safe.directoryin container jobs that run git. - Caller/job permissions may cap reusable workflow token capabilities.
- Rollback container image is coupled to
needs.core.outputs.image_tag. - Dispatch header still references removed
ci-container.yml.
Environment
- Repository:
vig-os/devcontainer - Downstream dispatch template:
assets/smoke-test/.github/workflows/repository-dispatch.yml - Referenced workspace workflows:
assets/workspace/.github/workflows/*.yml - GitHub Actions:
ubuntu-22.04, containerized jobs (ghcr.io/vig-os/devcontainer:<tag>)
Possible Solution
Address in one focused patch set:
- Add
git config --global --add safe.directory "$GITHUB_WORKSPACE"in container jobs that execute git:assets/workspace/.github/workflows/release.yml(rollback)assets/workspace/.github/workflows/release-core.yml(validate)assets/workspace/.github/workflows/release-publish.yml(publish)assets/workspace/.github/workflows/sync-main-to-dev.yml(check,sync)
- Add explicit caller/job permissions for reusable workflows and
ghoperations:release.ymlcaller jobs (core,publish)release-core.ymljobs requiringpull-requests/actionsscopes
- Decouple rollback container bootstrap from
needs.core.outputs.image_tagso rollback can start after earlycorefailure. - Update stale comment in
assets/smoke-test/.github/workflows/repository-dispatch.ymlthat referencesci-container.yml. - Optional hardening: align
prepare-release.ymlwithresolve-imageaction and add retry for image manifest validation.
Related Issues
- Related to Smoke-test dispatch failed for 0.3.1-rc7 #392 (smoke-test dispatch failure context)
Changelog Category
Fixed
Acceptance Criteria
- Containerized jobs that run git configure
safe.directoryconsistently. - Reusable workflow caller/job permissions are explicitly set to the minimal required scopes.
- Rollback starts even when
corefails before output emission. - Dispatch workflow comments no longer reference removed workflows.
- Optional:
prepare-releaseimage resolution/validation behavior is aligned with sharedresolve-imageconventions. - TDD compliance (see
.cursor/rules/tdd.mdc)
Metadata
Metadata
Assignees
Labels
area:ciCI/CD, GitHub Actions, workflowsarea:workflowDeveloper workflow, commands, rules, skillsbugSomething isn't workingeffort:smallLess than 1 hoursemver:patchBug fix, backward-compatible
Activity
test(ci): cover release rollback image and workflow hardening
fix(ci): harden release workflows for smoke-test orchestration
fix(ci): harden rollback failure gate for workspace release
fix(ci): harden smoke-test preflight and release workflow orchestrati…
chore: release 0.3.1 (#342)