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

ci: fix docker push logic when PR originates from fork #3324

Merged
merged 1 commit into from
Apr 12, 2023

Conversation

GenPage
Copy link
Member

@GenPage GenPage commented Apr 12, 2023

what

The atlantis-image workflow was attempting to push to our ghcr repo on a forked PR when that shouldn't be allowed. It was failing thankfully due to GITHUB_TOKEN permissions properly set to read-only.

why

The original conditional should have been github.event.pull_request.head.repo.full_name == github.repository not != but I found a cleaner way.

references

@GenPage GenPage requested a review from a team as a code owner April 12, 2023 20:34
@GenPage GenPage merged commit 2c726aa into main Apr 12, 2023
@GenPage GenPage deleted the ci/fix-push-on-fork-pr branch April 12, 2023 23:24
@nitrocode nitrocode added this to the v0.23.5 milestone Apr 16, 2023
mtavaresmedeiros pushed a commit to mtavaresmedeiros/atlantis that referenced this pull request Jul 3, 2023
ijames-gc pushed a commit to gocardless/atlantis that referenced this pull request Feb 13, 2024
ijames-gc pushed a commit to gocardless/atlantis that referenced this pull request Feb 13, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants