$ ansible --version && molecule --version
ansible 2.7.8
config file = None
configured module search path = [u'/Users/tomasz/.ansible/plugins/modules', u'/usr/share/ansible/plugins/modules']
ansible python module location = /Users/tomasz/Library/Python/2.7/lib/python/site-packages/ansible
executable location = /Users/tomasz/Library/Python/2.7/bin/ansible
python version = 2.7.15 (default, Feb 12 2019, 12:27:02) [GCC 4.2.1 Compatible Apple LLVM 10.0.0 (clang-1000.11.45.5)]
molecule, version 2.20.0
Molecule installation method (one of):
Ansible installation method (one of):
Detail any linters or test runners used:
create.yml phase.I'm trying to overwrite some domain with etc_hosts from docker_container module:
platforms:
- name: instance1
image: ubuntu:16.04
groups:
- haproxy-group
etc_hosts:
- "prometheus.local": "{{ ansible_default_ipv4.address }}"
There should be new entry in /etc/hosts:
172.17.0.3 prometheus.local
There's no entry in /etc/hosts:
root@instance1:/# cat /etc/hosts
127.0.0.1 localhost
::1 localhost ip6-localhost ip6-loopback
fe00::0 ip6-localnet
ff00::0 ip6-mcastprefix
ff02::1 ip6-allnodes
ff02::2 ip6-allrouters
172.17.0.3 instance1
Yep, we're missing that option.
'etc_hosts': {
'type': ['string', 'dict'],
'keysrules': {'type': 'string'},
},
Does now!