Feature #8333
closed
[SDKs] `arv keep docker` supports `repo:tag` image name scheme
Added by Brett Smith almost 9 years ago.
Updated about 7 years ago.
Description
Right now the syntax is arv keep docker repo tag
. We can keep supprting that, but adding support for arv keep docker repo:tag
would be more like the rest of the Docker universe, including other Arvados Docker references like the job runtime constraint.
- Target version set to Arvados Future Sprints
- Subject changed from [SDKs] `arv keep docker` supports `arv keep docker repo:tag syntax` to [SDKs] `arv keep docker` supports `repo:tag` image name scheme
Jeff Jasper from q^2 bumped into this problem. Can we fix this?
- Target version changed from Arvados Future Sprints to 2017-10-11 Sprint
- Assigned To set to Tom Clegg
- Status changed from New to In Progress
So it turns out that you can specify a port when using a custom registry, e.g. "myregistry.io:8888/repo/image:tag"
Here's how cwltool does it:
sp = dockerRequirement["dockerImageId"].split(":")
if len(sp) == 1:
sp.append("latest")
elif len(sp) == 2:
# if sp[1] doesn't match valid tag names, it is a part of repository
if not re.match(r'[\w][\w.-]{0,127}', sp[1]):
sp[0] = sp[0] + ":" + sp[1]
sp[1] = "latest"
elif len(sp) == 3:
if re.match(r'[\w][\w.-]{0,127}', sp[2]):
sp[0] = sp[0] + ":" + sp[1]
sp[1] = sp[2]
del sp[2]
repository = sp[0]
tag = sp[1]
8333-docker-repo-tag LGTM
- Status changed from In Progress to Resolved
Applied in changeset arvados|commit:4b4a0917a967c0ec2dd7b72c9665e0859022f120.
- Related to Bug #19840: Gets confused by port numbers in docker image name added
Also available in: Atom
PDF