-
Notifications
You must be signed in to change notification settings - Fork 1.1k
Allow private image pulls #13
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
|
Looks like some functions in the tests need to be updated to reflect newly required parameters. eg. RemoveImage() now requires *AuthConfig or nil edit: on second thought this may be testing with the wrong version of dockerclient |
|
Also i guess the change to ubuntu is a drastic one. I did this because the watchtower binary would not run in scratch or alpine....possibly due to dynamic linking? |
|
@frodopwns very cool. I've tested this and it seems to work well with Docker Hub but doesn't seem to support images pulled from a private (self-hosted) repo. |
|
@phumpal yeah it wasn't readily apparent to me in the https://github.com/samalba/dockerclient how you would pull from another registry. |
|
What's the status of this? |
|
@frodopwns: I checked and I think, you need to set the I'm not sure though ¯_(ツ)_/¯ |
| Password: password, | ||
| Email: email, | ||
| } | ||
| newContainerID, err = client.api.CreateContainer(config, name, &auth) |
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.
Maybe set dockerclient.URL manually to os.Getenv("REPO_REGISTRY"), if not empty, or something?
|
Looking into using other than Docker Hub repos with credentials... |
|
What's the status of this? Any chance it will support ECR Auth? |
|
Is there a timeline on this being merged? |
|
The switch to Ubuntu makes this pretty much worthless for any serious use given the amount of disk space it's killing now if you don't use Ubuntu:14.04 in other containers. The point of a watchtower should pretty much be sitting unobtrusively in a very small (5MB) corner of the system methinks. |
|
@curry684 that part probably isn't necessary. I just didn't want to use that previous image in my testing for some reason i can't remember. This is still just a go app so it should run anywhere go binaries do. |
|
I agree, but it still got merged. |
|
@frodopwns funny enough, changes in #21 aren't in master, despite github saying it has been merged. Am I missing something? |
This PR allows you to pass docker hub credentials to the watchtower image as ENV vars and thus find images that are private.