Log in to GitHub enterprise with jetbrains IDE (Intellij or Rider)
Asked Answered
A

2

8

There's no real guide for this, this is the existing documentation :

https://www.jetbrains.com/help/rider/GitHub.html

it's outdated.

Rider actually wants you to provide a token :

token login

this seems to not be the personal token.

I tried it with my server, it didn't work. login failure

There's also a button for generating the token which does not work.

it systematically generates github 404 pages : github 404

I assume the "Server" field is supposed to be in the

https://github.com/<SERVERNAME>

or

https://github.com/organizations/<SERVERNAME>

format.

but I cannot for the life of me figure out where I get the server's token from.

Again I did generate a github personal user token, but this one is refused by github enterprise login.

just like the personal user settings, the Github enterprise settings has a "developer settings" tab :

developer settings

but this tab seems to be for a different use, you create an "app" to be browsed on the "github app market", and I did create this but this is the full list of actions this gives access to :

actions

none of which involve giving me a token.

This is neither something that can be found in the options through brute force nor something that google yields results for.

I need help.

Update:

A bit more serching lead me to this doc : https://docs.github.com/en/actions/reference/authentication-in-a-workflow#modifying-the-permissions-for-the-github_token

it seems like the GITHUB_TOKEN they are talking about is the thing I would be interested in. at the top of the doc, the info-bubble claims this feature is not made available for users of Github free?

Is this what's going on?

this would be terrible communication on Github's and also Jet Brain's part. how are users to understand this and why does rider wish to force you to use this paid feature for integrating with github enterprise, when cloning the repo directly from a terminal that has your SSH key work just fine?

this is absurd. at the very least adding individual repos with github logins via SSH should be an available feature.

Aegir answered 19/5, 2021 at 0:52 Comment(3)
I think you misunderstand "github enterprise", it is not github.com. It is usually a "github.companydomian.com". Try going through: "File|Settings|Github|+|Login with Giithub"Gavin
@IvanShakhov I did that. my github enterprise projects aren't listed.Aegir
Try asking Rider support, accessible by Help->Contact SupportGavin
M
4

You need to enter the domain name where your Github enterprise is hosted.

enter image description here

Then you can click "Generate.." which opens Github in your browser enter image description here

Click the green Generate button at the bottom, and then copy and paste the token into IntelliJ.

This worked for me. You could also probably navigate to the "OAuth Apps" page yourself and create a new app with the correct permissions and paste the token in.

Mcripley answered 20/10, 2022 at 1:1 Comment(1)
GitHub Enterprise can be hosted, in which case the server is github.comLandin
L
2

If your organization is hosted at GitHub, the server is just github.com. Then you can click Generate and a web browser tab will launch, you will authenticate with your org credentials, and then it will take you to the page to generate the personal access token.

Once the token is generated, you have to copy & paste it back into the IntelliJ dialog.

Unfortunately, this ultimately does not work as the next time I open IntelliJ and look under file -> settings -> version control -> GitHub it shows my account as Missing access token.

UPDATE: I found it remembers the token if I set file -> settings -> appearance and behavior -> system settings -> passwords -> In KeePass

Landin answered 26/9, 2023 at 15:36 Comment(0)

© 2022 - 2025 — McMap. All rights reserved.