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

Support private git servers (like Github Enterprise instances) #660

Closed
nv35 opened this issue Jul 5, 2021 · 2 comments · Fixed by #2999
Closed

Support private git servers (like Github Enterprise instances) #660

nv35 opened this issue Jul 5, 2021 · 2 comments · Fixed by #2999
Assignees
Labels
good first issue Good for newcomers kind/enhancement New feature or request

Comments

@nv35
Copy link

nv35 commented Jul 5, 2021

Is your feature request related to a problem? Please describe.
I would like to run scorecard for a repository that is hosted on my Github Enterprise instance. I currently can't.

$ scorecard --repo github.corp.net/nv35/myrepo
2021/07/05 09:24:35 unsupported host: github.corp.net

Describe the solution you'd like
Allow to use the others github instances just like the .com one. The API path would likely just change from https://api.github.com/ to https://github.corp.net/api/v3, and I guess the calls would just be the same.

Additional context
The restriction to github.com is defined here:

return fmt.Errorf("%w: %s", ErrorUnsupportedHost, r.Host)

@nv35 nv35 added the kind/enhancement New feature or request label Jul 5, 2021
@naveensrinivasan
Copy link
Member

Is your feature request related to a problem? Please describe.
I would like to run scorecard for a repository that is hosted on my Github Enterprise instance. I currently can't.

$ scorecard --repo github.corp.net/nv35/myrepo
2021/07/05 09:24:35 unsupported host: github.corp.net

Describe the solution you'd like
Allow to use the others github instances just like the .com one. The API path would likely just change from https://api.github.com/ to https://github.corp.net/api/v3, and I guess the calls would just be the same.

Additional context
The restriction to github.com is defined here:

return fmt.Errorf("%w: %s", ErrorUnsupportedHost, r.Host)

PR's are welcome!

@azeemshaikh38
Copy link
Contributor

Thanks for this feedback! This is a great usecase for #462. We are still in the process of factoring out all github.com dependencies into RepoClient. Once we have this refactoring in place, it should be easy to use enterprise APIs instead of the regular one.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
good first issue Good for newcomers kind/enhancement New feature or request
Projects
None yet
4 participants