ReproNim / reproman

ReproMan (AKA NICEMAN, AKA ReproNim TRD3)
https://reproman.readthedocs.io
Other
24 stars 14 forks source link

ENH: docker: Pull :latest if no tag or digest is specified #488

Closed kyleam closed 4 years ago

kyleam commented 4 years ago

If a tag or digest isn't specified when calling reproman create, we download all tagged images. This behavior will likely be confusing to any callers that are familiar with the command-line interface to docker pull, which defaults to :latest if a tag or digest is omitted. And the behavior doesn't fit our goal: starting a new container from a single image.

Teach the DockerContainer resource to append ":latest" when it receives a bare image name.

Closes #483.

codecov[bot] commented 4 years ago

Codecov Report

Merging #488 into master will increase coverage by <.01%. The diff coverage is 100%.

Impacted file tree graph

@@            Coverage Diff             @@
##           master     #488      +/-   ##
==========================================
+ Coverage   89.64%   89.64%   +<.01%     
==========================================
  Files         148      148              
  Lines       12182    12190       +8     
==========================================
+ Hits        10920    10928       +8     
  Misses       1262     1262
Impacted Files Coverage Δ
reproman/resource/docker_container.py 94.15% <100%> (+0.15%) :arrow_up:
reproman/resource/tests/test_docker_container.py 100% <100%> (ø) :arrow_up:

Continue to review full report at Codecov.

Legend - Click here to learn more Δ = absolute <relative> (impact), ø = not affected, ? = missing data Powered by Codecov. Last update a5da59d...9e32712. Read the comment docs.

yarikoptic commented 4 years ago

upon a quick check I didn't find any indication that default tag could be anything than ":latest", so should be good to go.