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

Add support for GitHub Enterprise #768

Closed
slaweet opened this issue Apr 30, 2020 · 8 comments
Closed

Add support for GitHub Enterprise #768

slaweet opened this issue Apr 30, 2020 · 8 comments

Comments

@slaweet
Copy link

slaweet commented Apr 30, 2020

It would be useful to be able to connect the extension to an on-premise instance of GitHub Enterprise

I know that another GitHub extension allows that https://github.com/sindresorhus/refined-github

BTW thanks for a great extension 🥇

@fwouts
Copy link
Owner

fwouts commented Apr 30, 2020

Great idea!

It looks like it's almost a one-line change if we just wanted to point PR Monitor to GitHub Enterprise instead of GitHub.

However, I imagine you'd want it to collect PRs from both GitHub and GitHub Enterprise?

Heads-up, this might be a bit tricky to do on my own as I don't have access to GitHub Enterprise. I'll probably need some help from you :)

@slaweet
Copy link
Author

slaweet commented Apr 30, 2020

Thanks for the quick reply.

However, I imagine you'd want it to collect PRs from both GitHub and GitHub Enterprise?

Currently, I'm working mostly with GitHub Enterprise, so it would be enough for me 🙂

Heads-up, this might be a bit tricky to do on my own as I don't have access to GitHub Enterprise. I'll probably need some help from you :)

I can surely help with that.

@fwouts
Copy link
Owner

fwouts commented May 1, 2020

Cheers!

As a first step, would you mind trying out the extension with the one-line change shown in d0f753c (replacing with the correct domain for you)?

There are rudimentary instructions for building the extension locally in the README, let me know if they're insufficient :)

@slaweet
Copy link
Author

slaweet commented May 2, 2020

I tried to follow the install instructions in README. The only thing that was not straight-forward for me was step 4. But Google search helped. I'd suggest to include some link like https://www.cnet.com/how-to/how-to-install-chrome-extensions-manually/ (or some other if you know a better one) into step 4 in README.

Now my problem seems to be that I don't know the GitHub API endpoint of our GitHub Enterprise instance. Given our instance is on https://git.<my_domain>.io, I thought the API would be on https://api.github.<my_domain>.io or https://api.git.<my_domain>.io, but there's nothing. I don't know if the address is configurable or the API can be disabled altogether. I'll ask around at work on Monday and will get back to you 🙂

@fwouts
Copy link
Owner

fwouts commented May 3, 2020

Just a random thought. Have you tried https://api.github.git.<my_domain>.io?

@slaweet
Copy link
Author

slaweet commented May 4, 2020

So the API endpoint turned out to be https://git.<my_domain>.io/api/v3.

Changing the baseUrl seems to work perfectly:
Screenshot from 2020-05-04 14-17-41

I didn't yet have a chance to see a push notification, but I assume there is no reason it wouldn't work.

This solves my situation perfectly - I can run the custom-url extension in addition to the official one connected to GitHub.com

@fwouts
Copy link
Owner

fwouts commented May 4, 2020

That's awesome!

It does sound like a good long-term solution... I'd assume GitHub Enterprise users are a bit more security conscious so they'd appreciate having full control of the extension's code anyway.

Let's keep this issue open, and I'll write up some documentation to make it a bit easier for others to follow your lead.

Thanks for giving it a try 🙂

@fwouts
Copy link
Owner

fwouts commented May 8, 2020

Instructions added in 97c2e58, so I'll close this off. Feel free to open further issues if you find any bugs with the integration.

@fwouts fwouts closed this as completed May 8, 2020
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants