{"action":"created","issue":{"url":"https://api.github.com/repos/ansible/ansible-modules-core/issues/4706","repository_url":"https://api.github.com/repos/ansible/ansible-modules-core","labels_url":"https://api.github.com/repos/ansible/ansible-modules-core/issues/4706/labels{/name}","comments_url":"https://api.github.com/repos/ansible/ansible-modules-core/issues/4706/comments","events_url":"https://api.github.com/repos/ansible/ansible-modules-core/issues/4706/events","html_url":"https://github.com/ansible/ansible-modules-core/issues/4706","id":175094526,"number":4706,"title":"docker_container module got \"No such image\" when using same image with difference tag","user":{"login":"winggundamth","id":4833238,"avatar_url":"https://avatars.githubusercontent.com/u/4833238?v=3","gravatar_id":"","url":"https://api.github.com/users/winggundamth","html_url":"https://github.com/winggundamth","followers_url":"https://api.github.com/users/winggundamth/followers","following_url":"https://api.github.com/users/winggundamth/following{/other_user}","gists_url":"https://api.github.com/users/winggundamth/gists{/gist_id}","starred_url":"https://api.github.com/users/winggundamth/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/winggundamth/subscriptions","organizations_url":"https://api.github.com/users/winggundamth/orgs","repos_url":"https://api.github.com/users/winggundamth/repos","events_url":"https://api.github.com/users/winggundamth/events{/privacy}","received_events_url":"https://api.github.com/users/winggundamth/received_events","type":"User","site_admin":false},"labels":[{"url":"https://api.github.com/repos/ansible/ansible-modules-core/labels/bug_report","name":"bug_report","color":"fbca04"},{"url":"https://api.github.com/repos/ansible/ansible-modules-core/labels/cloud","name":"cloud","color":"c7def8"},{"url":"https://api.github.com/repos/ansible/ansible-modules-core/labels/docker","name":"docker","color":"e99695"},{"url":"https://api.github.com/repos/ansible/ansible-modules-core/labels/waiting_on_maintainer","name":"waiting_on_maintainer","color":"d93f0b"}],"state":"open","locked":false,"assignee":null,"assignees":[],"milestone":null,"comments":1,"created_at":"2016-09-05T15:36:05Z","updated_at":"2016-09-08T15:21:39Z","closed_at":null,"body":"##### ISSUE TYPE\r\n - Bug Report\r\n\r\n##### COMPONENT NAME\r\ndocker_container\r\n\r\n##### ANSIBLE VERSION\r\n```\r\nansible 2.1.1.0\r\n```\r\n\r\n##### CONFIGURATION\r\nN/A\r\n\r\n##### OS / ENVIRONMENT\r\nN/A\r\n\r\n##### SUMMARY\r\nI always got \"Error creating container: 404 Client Error: Not Found (\\\"No such image: xxx:yyy\\\")\" when using same image name with difference tag\r\n\r\n##### STEPS TO REPRODUCE\r\n```\r\n---\r\n- name: Run container\r\n  hosts: localhost\r\n  connection: local\r\n  gather_facts: no\r\n  tasks:\r\n    - name: run container with first tag\r\n      docker_container:\r\n        image: alpine:3.3\r\n        name: first_container\r\n        command: sleep 999\r\n    - name: run container with another tag\r\n      docker_container:\r\n        image: alpine:3.4\r\n        name: second_container\r\n        command: sleep 999\r\n```\r\n\r\n##### EXPECTED RESULTS\r\nIt should can be run without any error\r\n\r\n##### ACTUAL RESULTS\r\n```\r\n$ ansible-playbook --vault-password-file vault_pass tmp.yml -vvvv\r\nUsing /home/username/git/ansible/ansible.cfg as config file\r\n [WARNING]: Host file not found: /etc/ansible/hosts\r\n\r\n [WARNING]: provided hosts list is empty, only localhost is available\r\n\r\nLoaded callback default of type stdout, v2.0\r\n\r\nPLAYBOOK: tmp.yml **************************************************************\r\n1 plays in tmp.yml\r\n\r\nPLAY [Run container] ***********************************************************\r\n\r\nTASK [run container with first tag] ********************************************\r\ntask path: /home/username/git/ansible/tmp.yml:7\r\n<127.0.0.1> ESTABLISH LOCAL CONNECTION FOR USER: username\r\n<127.0.0.1> EXEC /bin/sh -c '( umask 77 && mkdir -p \"` echo $HOME/.ansible/tmp/ansible-tmp-1473089618.0-228211754531364 `\" && echo ansible-tmp-1473089618.0-228211754531364=\"` echo $HOME/.ansible/tmp/ansible-tmp-1473089618.0-228211754531364 `\" ) && sleep 0'\r\n<127.0.0.1> PUT /tmp/tmp08uTgz TO /home/username/.ansible/tmp/ansible-tmp-1473089618.0-228211754531364/docker_container\r\n<127.0.0.1> EXEC /bin/sh -c 'LANG=en_US.UTF-8 LC_ALL=en_US.UTF-8 LC_MESSAGES=en_US.UTF-8 /home/username/.virtualenvs/ansible/bin/python /home/username/.ansible/tmp/ansible-tmp-1473089618.0-228211754531364/docker_container; rm -rf \"/home/username/.ansible/tmp/ansible-tmp-1473089618.0-228211754531364/\" > /dev/null 2>&1 && sleep 0'\r\nchanged: [localhost] => {\"ansible_facts\": {\"ansible_docker_container\": {\"AppArmorProfile\": \"\", \"Args\": [\"999\"], \"Config\": {\"AttachStderr\": false, \"AttachStdin\": false, \"AttachStdout\": false, \"Cmd\": [\"sleep\", \"999\"], \"Domainname\": \"\", \"Entrypoint\": null, \"Env\": [\"PATH=/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin\"], \"Hostname\": \"1d5c227a2979\", \"Image\": \"alpine:3.3\", \"Labels\": {}, \"OnBuild\": null, \"OpenStdin\": false, \"StdinOnce\": false, \"Tty\": false, \"User\": \"\", \"Volumes\": null, \"WorkingDir\": \"\"}, \"Created\": \"2016-09-05T15:33:41.708003148Z\", \"Driver\": \"overlay2\", \"ExecIDs\": null, \"GraphDriver\": {\"Data\": {\"LowerDir\": \"/var/lib/docker/overlay2/3fa24abc4d1c7d7e8a582e90b0b7c07d19deba1c633a6e4414a5ee01fd6dff27-init/diff:/var/lib/docker/overlay2/63ffa0b5002627b003b6ec8ec3f81fedc9d8118ef6dd8289d1ec2f4d07391cd7/diff\", \"MergedDir\": \"/var/lib/docker/overlay2/3fa24abc4d1c7d7e8a582e90b0b7c07d19deba1c633a6e4414a5ee01fd6dff27/merged\", \"UpperDir\": \"/var/lib/docker/overlay2/3fa24abc4d1c7d7e8a582e90b0b7c07d19deba1c633a6e4414a5ee01fd6dff27/diff\", \"WorkDir\": \"/var/lib/docker/overlay2/3fa24abc4d1c7d7e8a582e90b0b7c07d19deba1c633a6e4414a5ee01fd6dff27/work\"}, \"Name\": \"overlay2\"}, \"HostConfig\": {\"AutoRemove\": false, \"Binds\": [], \"BlkioDeviceReadBps\": null, \"BlkioDeviceReadIOps\": null, \"BlkioDeviceWriteBps\": null, \"BlkioDeviceWriteIOps\": null, \"BlkioWeight\": 0, \"BlkioWeightDevice\": null, \"CapAdd\": null, \"CapDrop\": null, \"Cgroup\": \"\", \"CgroupParent\": \"\", \"ConsoleSize\": [0, 0], \"ContainerIDFile\": \"\", \"CpuCount\": 0, \"CpuPercent\": 0, \"CpuPeriod\": 0, \"CpuQuota\": 0, \"CpuShares\": 0, \"CpusetCpus\": \"\", \"CpusetMems\": \"\", \"Devices\": null, \"DiskQuota\": 0, \"Dns\": null, \"DnsOptions\": null, \"DnsSearch\": null, \"ExtraHosts\": null, \"GroupAdd\": null, \"IOMaximumBandwidth\": 0, \"IOMaximumIOps\": 0, \"IpcMode\": \"\", \"Isolation\": \"\", \"KernelMemory\": 0, \"Links\": null, \"LogConfig\": {\"Config\": {}, \"Type\": \"json-file\"}, \"Memory\": 0, \"MemoryReservation\": 0, \"MemorySwap\": 0, \"MemorySwappiness\": -1, \"NetworkMode\": \"default\", \"OomKillDisable\": false, \"OomScoreAdj\": 0, \"PidMode\": \"\", \"PidsLimit\": 0, \"PortBindings\": null, \"Privileged\": false, \"PublishAllPorts\": false, \"ReadonlyRootfs\": false, \"RestartPolicy\": {\"MaximumRetryCount\": 0, \"Name\": \"\"}, \"Runtime\": \"runc\", \"SecurityOpt\": null, \"ShmSize\": 67108864, \"UTSMode\": \"\", \"Ulimits\": null, \"UsernsMode\": \"\", \"VolumeDriver\": \"\", \"VolumesFrom\": null}, \"HostnamePath\": \"/var/lib/docker/containers/1d5c227a297954781c4cd363920bb404f8bb2e4cf4f0910eb47ad3ce4105a416/hostname\", \"HostsPath\": \"/var/lib/docker/containers/1d5c227a297954781c4cd363920bb404f8bb2e4cf4f0910eb47ad3ce4105a416/hosts\", \"Id\": \"1d5c227a297954781c4cd363920bb404f8bb2e4cf4f0910eb47ad3ce4105a416\", \"Image\": \"sha256:47cf20d8c26c46fff71be614d9f54997edacfe8d46d51769706e5aba94b16f2b\", \"LogPath\": \"/var/lib/docker/containers/1d5c227a297954781c4cd363920bb404f8bb2e4cf4f0910eb47ad3ce4105a416/1d5c227a297954781c4cd363920bb404f8bb2e4cf4f0910eb47ad3ce4105a416-json.log\", \"MountLabel\": \"\", \"Mounts\": [], \"Name\": \"/first_container\", \"NetworkSettings\": {\"Bridge\": \"\", \"EndpointID\": \"bf4ae339f169c0eaa0a5efdb6347a0de3dd90745ad6a04b1f9eafb95374ce2e3\", \"Gateway\": \"172.17.0.1\", \"GlobalIPv6Address\": \"\", \"GlobalIPv6PrefixLen\": 0, \"HairpinMode\": false, \"IPAddress\": \"172.17.0.11\", \"IPPrefixLen\": 16, \"IPv6Gateway\": \"\", \"LinkLocalIPv6Address\": \"\", \"LinkLocalIPv6PrefixLen\": 0, \"MacAddress\": \"02:42:ac:11:00:0b\", \"Networks\": {\"bridge\": {\"Aliases\": null, \"EndpointID\": \"bf4ae339f169c0eaa0a5efdb6347a0de3dd90745ad6a04b1f9eafb95374ce2e3\", \"Gateway\": \"172.17.0.1\", \"GlobalIPv6Address\": \"\", \"GlobalIPv6PrefixLen\": 0, \"IPAMConfig\": null, \"IPAddress\": \"172.17.0.11\", \"IPPrefixLen\": 16, \"IPv6Gateway\": \"\", \"Links\": null, \"MacAddress\": \"02:42:ac:11:00:0b\", \"NetworkID\": \"db1bc29f464b7995375de785a966e3f6ff8dced498c531f7705ec0e8d54bf0e2\"}}, \"Ports\": {}, \"SandboxID\": \"27999e70d0e1f23b06d01760159c894b74f1fa50f82ef44b55dfa1835ba0e6b5\", \"SandboxKey\": \"/var/run/docker/netns/27999e70d0e1\", \"SecondaryIPAddresses\": null, \"SecondaryIPv6Addresses\": null}, \"Path\": \"sleep\", \"ProcessLabel\": \"\", \"ResolvConfPath\": \"/var/lib/docker/containers/1d5c227a297954781c4cd363920bb404f8bb2e4cf4f0910eb47ad3ce4105a416/resolv.conf\", \"RestartCount\": 0, \"State\": {\"Dead\": false, \"Error\": \"\", \"ExitCode\": 0, \"FinishedAt\": \"0001-01-01T00:00:00Z\", \"OOMKilled\": false, \"Paused\": false, \"Pid\": 24138, \"Restarting\": false, \"Running\": true, \"StartedAt\": \"2016-09-05T15:33:42.016419065Z\", \"Status\": \"running\"}}}, \"changed\": true, \"invocation\": {\"module_args\": {\"api_version\": null, \"blkio_weight\": null, \"cacert_path\": null, \"capabilities\": null, \"cert_path\": null, \"cleanup\": false, \"command\": \"sleep 999\", \"cpu_period\": null, \"cpu_quota\": null, \"cpu_shares\": null, \"cpuset_cpus\": null, \"cpuset_mems\": null, \"debug\": false, \"detach\": true, \"devices\": null, \"dns_opts\": null, \"dns_search_domains\": null, \"dns_servers\": null, \"docker_host\": null, \"entrypoint\": null, \"env\": null, \"env_file\": null, \"etc_hosts\": null, \"exposed_ports\": null, \"filter_logger\": false, \"force_kill\": false, \"groups\": null, \"hostname\": null, \"image\": \"alpine:3.3\", \"interactive\": false, \"ipc_mode\": null, \"keep_volumes\": true, \"kernel_memory\": null, \"key_path\": null, \"kill_signal\": null, \"labels\": null, \"links\": null, \"log_driver\": \"json-file\", \"log_options\": null, \"mac_address\": null, \"memory\": \"0\", \"memory_reservation\": null, \"memory_swap\": null, \"memory_swappiness\": null, \"name\": \"first_container\", \"network_mode\": null, \"networks\": null, \"oom_killer\": null, \"paused\": false, \"pid_mode\": null, \"privileged\": false, \"published_ports\": null, \"pull\": false, \"purge_networks\": null, \"read_only\": false, \"recreate\": false, \"restart\": false, \"restart_policy\": null, \"restart_retries\": 0, \"security_opts\": null, \"shm_size\": null, \"ssl_version\": null, \"state\": \"started\", \"stop_signal\": null, \"stop_timeout\": null, \"timeout\": null, \"tls\": null, \"tls_hostname\": null, \"tls_verify\": null, \"trust_image_content\": false, \"tty\": false, \"ulimits\": null, \"user\": null, \"uts\": null, \"volume_driver\": null, \"volumes\": null, \"volumes_from\": null}, \"module_name\": \"docker_container\"}}\r\n\r\nTASK [run container with another tag] ******************************************\r\ntask path: /home/username/git/ansible/tmp.yml:12\r\n<127.0.0.1> ESTABLISH LOCAL CONNECTION FOR USER: username\r\n<127.0.0.1> EXEC /bin/sh -c '( umask 77 && mkdir -p \"` echo $HOME/.ansible/tmp/ansible-tmp-1473089622.12-49273116108204 `\" && echo ansible-tmp-1473089622.12-49273116108204=\"` echo $HOME/.ansible/tmp/ansible-tmp-1473089622.12-49273116108204 `\" ) && sleep 0'\r\n<127.0.0.1> PUT /tmp/tmpbAUuMp TO /home/username/.ansible/tmp/ansible-tmp-1473089622.12-49273116108204/docker_container\r\n<127.0.0.1> EXEC /bin/sh -c 'LANG=en_US.UTF-8 LC_ALL=en_US.UTF-8 LC_MESSAGES=en_US.UTF-8 /home/username/.virtualenvs/ansible/bin/python /home/username/.ansible/tmp/ansible-tmp-1473089622.12-49273116108204/docker_container; rm -rf \"/home/username/.ansible/tmp/ansible-tmp-1473089622.12-49273116108204/\" > /dev/null 2>&1 && sleep 0'\r\nfatal: [localhost]: FAILED! => {\"changed\": false, \"failed\": true, \"invocation\": {\"module_args\": {\"api_version\": null, \"blkio_weight\": null, \"cacert_path\": null, \"capabilities\": null, \"cert_path\": null, \"cleanup\": false, \"command\": \"sleep 999\", \"cpu_period\": null, \"cpu_quota\": null, \"cpu_shares\": null, \"cpuset_cpus\": null, \"cpuset_mems\": null, \"debug\": false, \"detach\": true, \"devices\": null, \"dns_opts\": null, \"dns_search_domains\": null, \"dns_servers\": null, \"docker_host\": null, \"entrypoint\": null, \"env\": null, \"env_file\": null, \"etc_hosts\": null, \"exposed_ports\": null, \"filter_logger\": false, \"force_kill\": false, \"groups\": null, \"hostname\": null, \"image\": \"alpine:3.4\", \"interactive\": false, \"ipc_mode\": null, \"keep_volumes\": true, \"kernel_memory\": null, \"key_path\": null, \"kill_signal\": null, \"labels\": null, \"links\": null, \"log_driver\": \"json-file\", \"log_options\": null, \"mac_address\": null, \"memory\": \"0\", \"memory_reservation\": null, \"memory_swap\": null, \"memory_swappiness\": null, \"name\": \"second_container\", \"network_mode\": null, \"networks\": null, \"oom_killer\": null, \"paused\": false, \"pid_mode\": null, \"privileged\": false, \"published_ports\": null, \"pull\": false, \"purge_networks\": null, \"read_only\": false, \"recreate\": false, \"restart\": false, \"restart_policy\": null, \"restart_retries\": 0, \"security_opts\": null, \"shm_size\": null, \"ssl_version\": null, \"state\": \"started\", \"stop_signal\": null, \"stop_timeout\": null, \"timeout\": null, \"tls\": null, \"tls_hostname\": null, \"tls_verify\": null, \"trust_image_content\": false, \"tty\": false, \"ulimits\": null, \"user\": null, \"uts\": null, \"volume_driver\": null, \"volumes\": null, \"volumes_from\": null}, \"module_name\": \"docker_container\"}, \"msg\": \"Error creating container: 404 Client Error: Not Found (\\\"No such image: alpine:3.4\\\")\"}\r\n\r\nNO MORE HOSTS LEFT *************************************************************\r\n\r\nPLAY RECAP *********************************************************************\r\nlocalhost                  : ok=1    changed=1    unreachable=0    failed=1   \r\n\r\nTASK: run container with first tag -------------------------------------- 4.23s\r\nTASK: run container with another tag ------------------------------------ 0.26s\r\n```\r\n"},"comment":{"url":"https://api.github.com/repos/ansible/ansible-modules-core/issues/comments/245633744","html_url":"https://github.com/ansible/ansible-modules-core/issues/4706#issuecomment-245633744","issue_url":"https://api.github.com/repos/ansible/ansible-modules-core/issues/4706","id":245633744,"user":{"login":"winggundamth","id":4833238,"avatar_url":"https://avatars.githubusercontent.com/u/4833238?v=3","gravatar_id":"","url":"https://api.github.com/users/winggundamth","html_url":"https://github.com/winggundamth","followers_url":"https://api.github.com/users/winggundamth/followers","following_url":"https://api.github.com/users/winggundamth/following{/other_user}","gists_url":"https://api.github.com/users/winggundamth/gists{/gist_id}","starred_url":"https://api.github.com/users/winggundamth/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/winggundamth/subscriptions","organizations_url":"https://api.github.com/users/winggundamth/orgs","repos_url":"https://api.github.com/users/winggundamth/repos","events_url":"https://api.github.com/users/winggundamth/events{/privacy}","received_events_url":"https://api.github.com/users/winggundamth/received_events","type":"User","site_admin":false},"created_at":"2016-09-08T15:21:39Z","updated_at":"2016-09-08T15:21:39Z","body":"ping @chouseknecht can you help me on this?"}}
{"actor":{"display_login":"winggundamth"}}