-
Notifications
You must be signed in to change notification settings - Fork 375
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
Added support for private repositories #23
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Looks really good! 😲 Just a few things:
GH_TOKEN
=>TOKEN
PRIVATE_BASE_URL
=>URL
Can we also add support for Now's NOW_URL
environment flag (which contains the URL of the current deployment)?
.gitignore
Outdated
@@ -3,3 +3,9 @@ node_modules | |||
|
|||
# logs | |||
npm-debug.log | |||
|
|||
# Docker |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Can you remove all of this after here? I don't see how it's necessary.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Sure, will do. Just added it for internal testing purposes
Just updated the PR 👨🔧 |
Thank you so much! 😍 |
Nice! Thank you for merging 😃 |
Thanks, @dominiklessel! |
@leo This was unfortunately broken with this commit For private repos, |
@karanjthakkar Yep. That would be wonderful! |
@dominiklessel @leo Can you share working example for Github private repo? |
This PR allows to set two new environment variables to enable support for private repos:
GH_TOKEN
- GitHub personal access token needed to access the private repo.PRIVATE_BASE_URL
- Base URL of the update server (e.g. update.example.com).Both are required to make hazel work with private repos.
The
proxyPrivateDownload
helper found in routes.js uses node-fetch to proxy the private file through hazel. This obviously leads to higher server load and increased bandwidth usage, but should be okay for this specific use case 😸