You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Currently we can provide only a single registry via configuration or system properties. However there are use case for which a pull and and a push can occur as a result of a single mvn call. E.g. mvn docker:build docker:push could potentially autopull base images for a registry A and push the resulting images to registry B.
This also implies that there can be two different set of authentication credentials are required, or maybe if no credentials at all.
In practice this is not so much an issue because authentication configuration comes from settings.xml or ~/.docker/config.json where multiple authentication specs can be stored (and looked up by registry). Also for pulling images which don't require an authentication but the (correct) authentication is send nevertheless doesn't harm (although not needed).
But for auth props given on the command line there is currently only one set which can be used (docker.username and docker.password) and its not clear whether it should be used for pull or push (albeit push is more likely of course).
Suggestion is:
Introduce a property docker.noAuthentication with values pull, push or all
Introduce a properties docker.pull.username and docker.pull.password (same for push) which overrides docker.username and docker.password if given. The latter are still used as default.
This issue was first mentioned in #147 . This is the followup issue.
Any opinions on this ?
The text was updated successfully, but these errors were encountered:
Registries can now be specified with 'docker.pull.registry' and 'docker.push.registry' (with a fallback 'docker.registry') as properties (or '<pullRegistry>' and '<pushRegistry>' in the plugin configuration.
Authentication can be specified also separately with 'docker.pull.username' / 'docker.push.username', ... and within the configuration in '<authConfig><push><username>...</username></push></authConfig' ....
Also added support autopulling and authentication of base images included in dockerfiles when 'dockerFileDir' is used. This fixes#358.
Currently we can provide only a single registry via configuration or system properties. However there are use case for which a pull and and a push can occur as a result of a single mvn call. E.g.
mvn docker:build docker:push
could potentially autopull base images for a registry A and push the resulting images to registry B.This also implies that there can be two different set of authentication credentials are required, or maybe if no credentials at all.
In practice this is not so much an issue because authentication configuration comes from
settings.xml
or~/.docker/config.json
where multiple authentication specs can be stored (and looked up by registry). Also for pulling images which don't require an authentication but the (correct) authentication is send nevertheless doesn't harm (although not needed).But for auth props given on the command line there is currently only one set which can be used (
docker.username
anddocker.password
) and its not clear whether it should be used for pull or push (albeit push is more likely of course).Suggestion is:
docker.noAuthentication
with valuespull
,push
orall
docker.pull.username
anddocker.pull.password
(same for push) which overridesdocker.username
anddocker.password
if given. The latter are still used as default.This issue was first mentioned in #147 . This is the followup issue.
Any opinions on this ?
The text was updated successfully, but these errors were encountered: