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

fix(github): allow Github App to clone forks of a private repository #2044

Merged
merged 1 commit into from
Apr 8, 2022

Conversation

joshuasimon-taulia
Copy link
Contributor

@joshuasimon-taulia joshuasimon-taulia commented Feb 3, 2022

closes #1696

i baked an image with my changes. running atlantis against private forks now works in my installation

fix: only fetch "pull/$PR_NUMBER/head" when githubAppEnabled
@joshuasimon-taulia
Copy link
Contributor Author

@nishkrishnan @chenrui333 @jamengual could i get some feedback?

Copy link
Member

@chenrui333 chenrui333 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Can you add some tests for this? Thanks!

@chenrui333
Copy link
Member

@joshuasimon-taulia looks pretty straightforward, can you please add some tests? It should be good to go after that. 🙏

@joshuasimon-taulia
Copy link
Contributor Author

are there any existing test cases i can easily copy/paste from?

i took a peek into https://github.com/runatlantis/atlantis/blob/7a927c050b945ccae64850f327c1309c2448aa2a/server/events/github_app_working_dir_test.go, but i don’t see an immediately obvious way to mock a private github fork.

@chenrui333
Copy link
Member

Alright, that is fine then.

@chenrui333 chenrui333 changed the title fix: allow Github App to clone forks of a private repository fix(github): allow Github App to clone forks of a private repository Mar 7, 2022
@chenrui333 chenrui333 modified the milestones: v0.19.1, v0.19.2 Mar 7, 2022
@jamengual
Copy link
Contributor

thanks for the contribution @joshuasimon-taulia

@jamengual jamengual merged commit 25eea31 into runatlantis:master Apr 8, 2022
krrrr38 pushed a commit to krrrr38/atlantis that referenced this pull request Dec 16, 2022
…ntis#2044)

fix: only fetch "pull/$PR_NUMBER/head" when githubAppEnabled
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.

Atlantis using Github App unable to clone fork of a private repository
3 participants