ci(nightly): scheduled nightly build + smoke + optional pre-release - #93
Merged
Conversation
Add .github/workflows/nightly.yml: a scheduled (07:00 UTC daily) + workflow_dispatch lane that runs the full nightly gate (fmt-check, vet, 4-target CGO-free cross-build, CGO=1 test-race, determinism) via a new `make nightly` target, plus an optional, default-OFF goreleaser snapshot pre-release job gated on the NIGHTLY_PRERELEASE repo variable that uploads artifacts (never a git tag, never a semver release). Both jobs are guarded by `github.repository == 'open-source-cloud/devstack'` so scheduled/dispatch runs no-op on forks. The pre-release path publishes goreleaser SNAPSHOT artifacts as workflow artifacts only — it never creates a `nightly` git tag, which would confuse goreleaser's git describe and break release-dryrun on every PR (MEMORY: no-non-semver-tags). Also adds `make cross` (4-target build smoke) and `make nightly` (make ci + cross + determinism) to mirror the workflow locally. Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
What
Adds a scheduled Nightly GitHub Actions lane plus supporting Makefile targets.
.github/workflows/nightly.ymlschedule: cron '0 7 * * *'(07:00 UTC daily) +workflow_dispatch.nightlyjob runs the fullmake ciequivalent plus the 4-target CGO-free cross-build and the determinism assertion, via a singlemake nightlytarget: fmt-check → vet →cross(linux/darwin × amd64/arm64,CGO_ENABLED=0) →test-race(CGO_ENABLED=1) →determinism.check-latest: trueon setup-go so the lane picks up new Go point releases (the whole point of a nightly).if: github.repository == 'open-source-cloud/devstack'so scheduled/dispatch runs no-op on forks.prereleasejob (default OFF): gated on the repo variableNIGHTLY_PRERELEASE == 'true'. Runs goreleaser in snapshot mode and uploads the tarballs/.deb/.rpm/checksums as workflow artifacts (7-day retention). It never creates a GitHub Release and never pushes a git tag.Makefile: newcross(4-target build smoke) andnightly(make ci + cross + determinism) targets; added to.PHONY.Why
Catch drift the per-PR CI can miss — a new Go release, a transitive dep that breaks a cross-compile target, or non-deterministic generation — before it bites a real release.
Deliberately no semver release and no git tag: a stray non-semver tag (e.g.
nightly) confuses goreleaser'sgit describeand breaksrelease-dryrunon every PR (per the repo's no-non-semver-tags rule). Nightly builds surface as workflow artifacts only.How tested
gofmt -l .clean,go vet ./...clean,CGO_ENABLED=0 go build ./...ok.CGO_ENABLED=1 go test ./internal/...all green.make -n nightlyexpands to the expected fmt-check/vet/cross/test-race/determinism chain.nightly.ymlvalidated withyaml.safe_load(parses ok).🤖 Generated with Claude Code