Skip to content
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

Fail workflow if permissions do not allow dependency graph submission #997

Closed
pioterj opened this issue Dec 13, 2023 · 0 comments · Fixed by #1036
Closed

Fail workflow if permissions do not allow dependency graph submission #997

pioterj opened this issue Dec 13, 2023 · 0 comments · Fixed by #1036
Labels
enhancement New feature or request
Milestone

Comments

@pioterj
Copy link
Member

pioterj commented Dec 13, 2023

When the submission of dependency graph is enabled via with: dependency-graph: generate-and-submit but permissions are not sufficient with permissions: contents: read instead of write, the following warning in the annotations in summary of the build is displayed:

Failed to submit dependency graph dependency-graph-reports/build_description_service-build.json. Please ensure that the 'contents: write' permission is available for the workflow job. Note that this permission is never available for a 'pull_request' trigger from a repository fork.

The build still passes which makes it easy to miss. It would be better to fail the workflow run in case such misconfiguration is detected.

@bigdaz bigdaz added the enhancement New feature or request label Jan 8, 2024
@bigdaz bigdaz changed the title Fail early if the configuration does not allow dependency graph submission Fail workflow if permissions do not allow dependency graph submission Jan 12, 2024
@bigdaz bigdaz added this to the 3.0.0 milestone Jan 12, 2024
@bigdaz bigdaz closed this as completed in 7099569 Jan 13, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants