-
Notifications
You must be signed in to change notification settings - Fork 1.4k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Granular Workflow Permissions #19026
Open
nubtron
wants to merge
2
commits into
master
Choose a base branch
from
nubtron/granular-workflow-permissions
base: master
Could not load branches
Branch not found: {{ refName }}
Loading
Could not load tags
Nothing to show
Loading
Are you sure you want to change the base?
Some commits from the old base branch may be removed from the timeline,
and old review comments may become outdated.
Open
+28
−3
Conversation
This file contains 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
Permissions Test |
2 similar comments
Permissions Test |
Permissions Test |
nubtron
force-pushed
the
nubtron/granular-workflow-permissions
branch
from
November 13, 2024 09:01
d466f6f
to
46a62bd
Compare
nubtron
force-pushed
the
nubtron/granular-workflow-permissions
branch
from
November 13, 2024 16:54
46a62bd
to
1583b10
Compare
datadog-agent-integrations-bot
bot
added
team/agent-integrations
team/agent-delivery
new name for agent-build-and-delivery
labels
Nov 13, 2024
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Labels
agent/review-requested
changelog/no-changelog
dev/testing
dev/tooling
docs/review-requested
ecosystems/review-requested
product/review-requested
qa/skip-qa
Automatically skip this PR for the next QA
team/agent-delivery
new name for agent-build-and-delivery
team/agent-integrations
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 does this PR do?
This PR implements the necessary preparations to set default workflow permissions to "Read-only" and to disable "Allow GitHub Actions to create and approve pull requests". We want to set those options to their most restrictive values for security reasons. See https://datadoghq.atlassian.net/browse/VULN-8234 for more information.
I did my best to isolate and test steps that might require permissions, but since actions that require permissions typically have side effects (for eg. creating a release), I didn't test everything. If you get permission issues after this PR is merged reach out to me!
The permissions affect GITHUB_TOKEN.
Here are some jobs that were confirmed not to require write permissions:
Our actions that update dependencies, label PRs or create backports should not be affected as they use the Agent Integrations App key, not the GitHub token.
Temporary workflow I used to check permissions:
https://github.com/DataDog/integrations-core/actions/runs/11818825782/workflow
Here is a run:
https://github.com/DataDog/integrations-core/actions/runs/11798454943/job/32864652866
Motivation
This PR is the first step in complying with https://datadoghq.atlassian.net/browse/VULN-8234.
Review checklist (to be filled by reviewers)
qa/skip-qa
label if the PR doesn't need to be tested during QA.backport/<branch-name>
label to the PR and it will automatically open a backport PR once this one is merged