From 6a9ea0f5dc609768e99f3e38e20f60401e3da2a1 Mon Sep 17 00:00:00 2001 From: Michal Zegan Date: Mon, 27 May 2019 13:57:24 +0200 Subject: Add the prepare-dns role This role can be used by infra playbook or dns role tests to download the dnsmasq docker images used during test. Change-Id: I05d9ccd1f2ac3d635c032b43078ca9a2179cb547 Issue-ID: OOM-1818 Signed-off-by: Samuli Silvius Signed-off-by: Michal Zegan --- ansible/test/roles/prepare-dns/tasks/main.yml | 22 ++++++++++++++++++++++ 1 file changed, 22 insertions(+) create mode 100644 ansible/test/roles/prepare-dns/tasks/main.yml (limited to 'ansible/test/roles') diff --git a/ansible/test/roles/prepare-dns/tasks/main.yml b/ansible/test/roles/prepare-dns/tasks/main.yml new file mode 100644 index 00000000..7907f868 --- /dev/null +++ b/ansible/test/roles/prepare-dns/tasks/main.yml @@ -0,0 +1,22 @@ +--- +- name: "Create needed dirs for dns role" + file: + path: "{{ item }}" + state: directory + mode: "u+rw,g+wx,o+rwx" + recurse: true + loop: + - "{{ app_data_path }}/cfg" + - "{{ infra_images_path }}" + +- name: Download and archive dnsmasq docker image for the dns role to use + delegate_to: localhost + docker_image: + name: andyshinn/dnsmasq + tag: 2.76 + archive_path: /tmp/dnsmasq.tar + +- name: Copy dnsmasq image to node + copy: + src: /tmp/dnsmasq.tar + dest: "{{ infra_images_path }}/{{ dns_server_image_tar }}" -- cgit 1.2.3-korg