-
Notifications
You must be signed in to change notification settings - Fork 645
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
Add support for alternate credential stores #534
Comments
For this we probably have to reach out for some external helper tool, which shouldn't be a problem (if optional). Of course, a pure Java solution would be awesome, but I'm afraid thats not possible. Currently we also have support for docker-machine where we call an external command, so we already have the 'machinery'. So the idea would be to reach out to |
I can confirm the issue on MacOS. I'm working with a private registry, and I can no longer transparently log in with the credentials stored in What's worse, trying to start a container for an image which needs to be pulled from the registry, I'm getting the following stack trace:
Even if it's not feasible to access the As a workaround, I added a Docker version 17.03.0-ce |
agree that we should be more polite here. |
What server tag did you add ? I'm sorry how was this issue fixed it's not clear to me. |
Putting my repo credentials in a server block in my settings.xml, with the registry name as the id, worked for me: <server>
<id>my-docker.jfrog.io</id>
<username>foo</username>
<password>bar</password>
</server> Then in the pom: <build>
<pluginManagement>
<plugins>
<plugin>
<groupId>io.fabric8</groupId>
<artifactId>docker-maven-plugin</artifactId>
<version>0.21.0</version>
<configuration>
<registry>my-docker.jfrog.io</registry> |
It seems that the workaround above will not work nicely with AWS ECR since it generates a temporary user/password. Is there a work around for AWS ECR? |
I'm running into same issue, OSX Docker for Mac with AWS ECR. Has anyone figured out a work around for this combination? |
@rodlogic For ECR I just sorted a way to get this working again. I set the property docker.skip.extendedAuth to true like: mvn -Ddocker.skip.extendedAuth=true clean package docker:build I have a script that calls the ecr get-login --no-include-email bit to get the temp credentials. Using the property bypasses the logic that trys to use it's own logic using API credentials. I wasn't able to get it to work using the settings.xml and API keys. I was able to get it to work using the section but I obviously didn't want to include API creds in the pom. Setting the property above property via POM didn't work, I had to pass via the maven command line. Back in business with that. As an Update!! That worked for a build request but then died when I tried to do a Docker:Push. When I stopped bypassing the extended Auth using the above property, the push worked. I suspect it's a cached entry in the keychain which I've dealt with before using CodeCommit on MacOS. I used an AppleScript for that, so I've just created another script to clear the cached credential. Here is the link to the script I wrote. That might deal with this issue. :) https://gist.github.com/jghankins/650fecfa333f5d53419593bcf4a0284f |
This issue is resolved here: #731 |
Credential helper support has been added and a serious bug fixed in 0.25.2 (soon to be released) for a login to index.docker.io. Please reopen a new issue if there is anything left to do. |
It would seem that in the latest versions of Docker, there may be a shift from Docker handling the storage of registry credentials in it's
~/.docker/config.json
to using 3rd-party or OS provided credential managers. See the docker login reference and docker-crenetial-helpers project for more details on this and the implementation.This is certainly, the default configuration as it stands for Windows as running
docker login
will not add the older format of anauths
with server objects that have anauth
token (as happens with docker on Linux right now).From what I can see, and I could be mistaken having only had a quick browse of the source online, but the current implementation relies on either a
username
/password
pair in theconfig.json
or anauth
token. Implementation would require the checking of thecredsStore
field with dispatch the appropriate implementation as well as concrete implementations being provided forosxkeychain
,secretservice
andwincred
.I will reproduce and add the log output for the error when trying to pull or push from a windows system where it will use
"credsStore": "win"
when I get a chance.There has been some discussion on this with the #532 PR.
The text was updated successfully, but these errors were encountered: