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

Implement hlx auth --github #579

Closed
tripodsan opened this issue Feb 22, 2019 · 4 comments
Closed

Implement hlx auth --github #579

tripodsan opened this issue Feb 22, 2019 · 4 comments
Assignees
Labels
enhancement New feature or request

Comments

@tripodsan
Copy link
Contributor

Description
there should be a simple way to retrieve the credentials that are required for depoyment from the various backends (see #380 (comment))

this issue is about adding hlx auth --github which will initiate the authentication process with github for the user to generate a token as helix bot. see https://github.com/adobe/helix-bot/issues/33 for details.

@tripodsan tripodsan added the enhancement New feature or request label Feb 22, 2019
@tripodsan tripodsan self-assigned this Feb 22, 2019
@tripodsan
Copy link
Contributor Author

tripodsan commented Feb 22, 2019

example output:

$ hlx auth --github

Thank you for choosing the automatic Helix Bot Authentication process.
I will shortly open a browser with the following url. In case the browser doesn't
open automatically, please navigate to the url manually:

   https://app.project-helix.io/login/start?p=1234.

Oh, and I started local server, bound to 127.0.0.1:1234 and am awaiting the completion 
of the process.

<<spinner spinning>>

The authentication process has completed. Thank you. 
I received an access token that I can use to access the Helix Bot on your behalf. 

If you wish, I can add it automatically to a file [Y/n]: ?
which file: [.env]: ?

ok. I added it to `.env`.

----< or >-----
ok. here's the token for you:
HLX_GITHUB_TOKEN=fsdfgsdfgsdfgdsfgdsfg

You can now close the browser window if it didn't close automatically.

@tripodsan
Copy link
Contributor Author

would need #580

@trieloff
Copy link
Contributor

Sounds good. When you ask the "should I save this stuff" question, check first that this is an interactive (TTY) environment.

@tripodsan
Copy link
Contributor Author

...check first that this is an interactive (TTY) environment.

I think that the entire interactive hlx auth should only work on a TTY.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
Development

No branches or pull requests

2 participants