-
Notifications
You must be signed in to change notification settings - Fork 2k
Allow username/password in config file #2122
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
Conversation
Signed-off-by: Jon Johnson <jonjohnson@google.com>
|
ping @tiborvass Came across this when I switched over to using docker/cli for config file parsing. Docker seems to ignore the username/password fields from a config file if they're set directly instead of the "auth" field. |
|
@silvin-lubecki @chris-crone @vdemeester Could you please take a look at this small fix. It would really help. Thanks! |
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.
LGTM 🐯
Signed-off-by: Jon Johnson <jonjohnson@google.com>
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.
LGTM
|
@jonjohnsonjr linter is complaining
|
Signed-off-by: Jon Johnson <jonjohnson@google.com>

Formed in 2009, the Archive Team (not to be confused with the archive.org Archive-It Team) is a rogue archivist collective dedicated to saving copies of rapidly dying or deleted websites for the sake of history and digital heritage. The group is 100% composed of volunteers and interested parties, and has expanded into a large amount of related projects for saving online and digital history.

- What I did
Only decode
authif it is present. Currently, this overwritesusernameandpasswordfields, even ifauthis empty.Fixes google/go-containerregistry#555
- How I did it
Guard
decodeAuthwith an empty string check.- How to verify it
Run the unit test :)
Alternatively, modify your config file to use username/password instead of auth and try it. I have a branch here which seems to work when I try it 👍
- Description for the changelog
Fix reading config files containing "username" and "password" auth.