I have another playbook that sets up a docker container, and now I want to 
add to the hosts file. Why does this not work?

- name: Add host entry
  docker_container:
    name: "{{ item }}"
    etc_hosts: "{'server.place.com': '{{ server_ip }}'}"
  with_items:
    - "container1"
    - "container2"

TASK [awx : Add host entry] 
*************************************************************************************

failed: [123.123.123.123] (item= container1) => {"changed": false, "item": 
"container1", "msg": "Error creating container: 400 Client Error: Bad 
Request (\"No command specified\")"}

failed: [123.123.123.123] (item= container2) => {"changed": false, "item": 
"container2", "msg": "Error creating container: 400 Client Error: Bad 
Request (\"No command specified\")"}

If this is a bug, I'm happy to submit a report. I just wanted to make sure 
I wasn't doing something wrong. 

-- 
You received this message because you are subscribed to the Google Groups 
"Ansible Project" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to [email protected].
To post to this group, send email to [email protected].
To view this discussion on the web visit 
https://groups.google.com/d/msgid/ansible-project/62db2b4a-afe2-492a-a69b-b1fae245a057%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.

Reply via email to