Remove the pull_request
trigger for the documentation
workflow
#1490
+0
−1
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.
Issue
The
documentation
workflow is triggered to run on both all pull requests and pushes tomaster
. The former cannot (and should not) succeed on PRs from the public, even if the workflow is manually triggered by some with write permissions (Oxide). This has caused checks by public PRs to fail, such as #1488 with https://github.com/oxidecomputer/hubris/actions/runs/5838750982/job/15876474521?pr=1488.Additionally, we probably don't want to trigger the workflow on pull requests, because it'd mean the live GH pages are updated before a PR is accepted. For example: https://github.com/oxidecomputer/hubris/pull/1489/files can be seen on https://oxidecomputer.github.io/hubris/reference/.
Fix
This PR just removes the trigger on
pull_reqeusts
while keeping the trigger on changes to themaster
branch, so the GH pages at https://oxidecomputer.github.io/hubris/reference/ should only reflect what's onmaster
.It might make sense to refine the trigger to run on changes to the
doc
directory, but this will at least resolve the issues.Notes
The
JamesIves/github-pages-deploy-action
action uses the builtinGITHUB_TOKEN
by default, which cannot have write permissions to the repo (https://docs.github.com/en/actions/security-guides/automatic-token-authentication#permissions-for-the-github_token).