This repository was archived by the owner on Jan 22, 2024. It is now read-only.

Description
Expected results (as docker cli does)
hholst@fb-hholst3 ~
$ CID=$(docker run -dit alpine:latest sh)
Unable to find image 'alpine:latest' locally
latest: Pulling from library/alpine
0a8490d0dfd3: Pulling fs layer
0a8490d0dfd3: Verifying Checksum
0a8490d0dfd3: Download complete
0a8490d0dfd3: Pull complete
Digest: sha256:dfbd4a3a8ebca874ebd2474f044a0b33600d4523d03b0df76e5c5986cb02d7e8
Status: Downloaded newer image for alpine:latest
hholst@fb-hholst3 ~
$ echo $CID
585df99e599e6024de6eb3ea0b449640b4704d9c049e62762281002fb06c396c
Nvidia docker result:
hholst@fb-hholst3 ~
$ CID=$(nvidia-docker run -dit alpine:latest sh)
hholst@fb-hholst3 ~
$ echo $CID
latest: Pulling from library/alpine 0a8490d0dfd3: Pulling fs layer 0a8490d0dfd3: Verifying Checksum 0a8490d0dfd3: Download complete 0a8490d0dfd3: Pull complete Digest: sha256:dfbd4a3a8ebca874ebd2474f044a0b33600d4523d03b0df76e5c5986cb02d7e8 Status: Downloaded newer image for alpine:latest 60649d2e04a5ed5ca5d80e286bd8ee6c701ef817f97ccc60cc0611729261e334
Notes
Please note that you need to remove the image before running the command with docker rmi alpine:latest.