Repository navigation
ci(release): ask the website to rebuild once the release exists - #24
Merged
Merged
Conversation
spawner.run builds its docs from the latest release, at a daily run that GitHub also stops after 60 days without activity in its repository. Once the GitHub release of a stable version exists, the release job sends it a repository_dispatch (spawner-release), with SITE_DISPATCH_TOKEN: a secret of the release environment, so that only that job reads it, holding a fine-grained token limited to Flosk6/spawner-site (Contents in read and write, which repository_dispatch needs). Without the token, or once it expires, the step says so and the release goes on.
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 and why
https://spawner.run builds its documentation from the latest release of Spawner. Today it notices a release at its daily build, up to a day later, and GitHub stops scheduled workflows after 60 days without activity in a public repository: the site could stop following the releases without a word.
Once the GitHub release of a stable version exists, the release job now sends a
repository_dispatch(spawner-release) toFlosk6/spawner-site, whose deploy workflow already listens for it.SITE_DISPATCH_TOKEN, a secret of thereleaseenvironment rather than of the repository: only the release job, which a reviewer approves, reads it. It is a fine-grained token limited toFlosk6/spawner-site, with Contents in read and write, the only permissionrepository_dispatchaccepts. It is a step of the existing release job, so no third approval.continue-on-error); the daily build still follows the release. Prereleases do not trigger it, since the site follows the latest stable release.scripts/README.mdandarchitecture.mdsay so.Checks
Tests next to the code, a compose fixture for a policy change, or an end-to-end check
Documentation and
CHANGELOG.mdupdated when the behaviour changes (nothing users notice: no changelog line)release.ymlis valid YAML; the new step's script passesbash -n.Not run yet: the first stable release after this merges sends the event. The receiving side (the site's deploy on
repository_dispatch) is checked once 2.2.0 is out.