diff --git a/molecule/default/molecule.yml b/molecule/default/molecule.yml index eeac777..73a3003 100644 --- a/molecule/default/molecule.yml +++ b/molecule/default/molecule.yml @@ -7,6 +7,9 @@ platforms: - name: instance image: docker.io/pycontribs/centos:8 pre_build_image: true + published_ports: + - 127.0.0.1:2080:80 + - 127.0.0.1:2443:443 provisioner: name: ansible verifier: diff --git a/src/molecule_podman/playbooks/create.yml b/src/molecule_podman/playbooks/create.yml index a08712f..cc79f30 100644 --- a/src/molecule_podman/playbooks/create.yml +++ b/src/molecule_podman/playbooks/create.yml @@ -156,7 +156,7 @@ {% if item.tmpfs is defined %}{% for i in item.tmpfs %}--tmpfs={{ i }} {% endfor %}{% endif %} {% if item.capabilities is defined %}{% for i in item.capabilities %}--cap-add={{ i }} {% endfor %}{% endif %} {% if item.exposed_ports is defined %}--expose="{{ item.exposed_ports|join(',') }}"{% endif %} - {% if item.published_ports is defined %}{% for i in item.published_ports %}--publish={{ i }}{% endfor %}{% endif %} + {% if item.published_ports is defined %}{% for i in item.published_ports %}--publish={{ i }} {% endfor %}{% endif %} {% if item.ulimits is defined %}{% for i in item.ulimits %}--ulimit={{ i }} {% endfor %}{% endif %} {% if item.dns_servers is defined %}--dns="{{ item.dns_servers|join(',') }}"{% endif %} {% if item.env is defined %}{% for i,k in item.env.items() %}--env={{ i }}={{ k }} {% endfor %}{% endif %}