19 lines
417 B
YAML
19 lines
417 B
YAML
---
|
|
- name: Set etc_hosts_file if running in Docker
|
|
set_fact:
|
|
__etc_hosts_file: "{{ __etc_hosts_file }}.docker"
|
|
when:
|
|
- ansible_virtualization_type == "docker" or
|
|
ansible_virtualization_type == "podman" or
|
|
ansible_virtualization_type == "container"
|
|
|
|
|
|
- name: Deploy {{ __etc_hosts_file }}
|
|
template:
|
|
src: templates/etc_hosts.j2
|
|
dest: "{{ __etc_hosts_file }}"
|
|
mode: 0644
|
|
|
|
|
|
...
|