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

Enable login via env vars (for CI) #2

Merged
merged 1 commit into from Jan 6, 2022
Merged

Conversation

spkane
Copy link
Collaborator

@spkane spkane commented Jan 6, 2022

Signed-off-by: Sean P. Kane sean@superorbital.io

- What I did

Borrowed code from docker#198 to make it possible to login via environment variables for CI workflows.

- How I did it

Via a few lines of Go code.

- How to verify it

Run hub-tool logout

export DOCKER_USERNAME=hub_username
export DOCKER_PASSWORD=hub_password
hub-tool login
hub-tool tag ls registry
  • You should not be prompted for the username or password, and you should be able to run other commands now.

- Description for the changelog

  • Allow non-interactive login via the DOCKER_USERNAME and DOCKER_PASSWORD env vars.

Signed-off-by: Sean P. Kane <sean@superorbital.io>
@spkane spkane merged commit 9416108 into main-fork Jan 6, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
1 participant