feat: add support for github enterprise server#132
Conversation
andyfeller
left a comment
There was a problem hiding this comment.
For what it's worth, these changes look good to me ![]()
| GithubHostname := os.Getenv("GITHUB_HOSTNAME") | ||
| baseUrl := fmt.Sprintf("https://%s/", GithubHostname) | ||
|
|
||
| githubClient, _ = github.NewEnterpriseClient(baseUrl, baseUrl, tc) |
There was a problem hiding this comment.
NewEnterpriseClient function checks out 👌 ... I was initially asking whether this took into account the path aspects for GHES API endpoints, but confirmed that it should be handled appropriately.
|
@brikis98 can you help with an approval for this PR? |
|
@brikis98 @zackproser : is there someone else at Gruntworks who might be capable of reviewing and approving this PR? 🙏 |
|
@andyfeller you could try @josh-padnick or @hongil0316 ? |
|
@gitsstewart Could you identify an SME to help review this PR? |
|
I will ask the team if anyone is available quickly for a review |
james00012
left a comment
There was a problem hiding this comment.
Small nit comment but overall LGTM. Let me trigger the test pipeline
|
|
||
| var githubClient *github.Client | ||
|
|
||
| if os.Getenv("GITHUB_HOSTNAME") != "" { |
There was a problem hiding this comment.
nit: can we change the environment variable name to something like: GITHUB_URL and expect the user to pass in the full URL? This would potentially remove confusion from users whether they would have to include https: at the front or not.
|
Confirmed that all the tests passed. Will merge. |
|
This will be very helpful to my team! @hongil0316 - could you release a new version with this feature? |
|
@hongil0316 I'll go ahead and issue the release since the only thing it includes is this change. |
|
Released in v0.1.11 |
|
Oh sorry about that @thirstydeveloper, I must have missed this. Thanks @josh-padnick for taking it! :) |
Description
This PR adds support for Github Enterprise. I used this PR as a guide, and added a small test.
TODOs
Read the Gruntwork contribution guidelines.
Release Notes (draft)
Added support for Github Enterprise servers.