diff --git a/Linux/external-data-mirror/ansible/external-data-mirror.yml b/Linux/external-data-mirror/ansible/external-data-mirror.yml index 3c046ca..0e7b2c2 100644 --- a/Linux/external-data-mirror/ansible/external-data-mirror.yml +++ b/Linux/external-data-mirror/ansible/external-data-mirror.yml @@ -3,7 +3,13 @@ roles: - role: dannixon.system.interactive_users - tags: "initial-setup" - - role: mirror + tags: "setup" + - role: geerlingguy.docker become: yes - tags: "mirror" \ No newline at end of file + tags: "setup" + - role: mirror-data + become: yes + tags: "mirror" + - role: server + become: yes + tags: "server" diff --git a/Linux/external-data-mirror/ansible/requirements.yml b/Linux/external-data-mirror/ansible/requirements.yml new file mode 100644 index 0000000..2e4d2e7 --- /dev/null +++ b/Linux/external-data-mirror/ansible/requirements.yml @@ -0,0 +1,3 @@ +--- +roles: + - src: geerlingguy.docker diff --git a/Linux/external-data-mirror/ansible/roles/mirror/defaults/main.yml b/Linux/external-data-mirror/ansible/roles/mirror-data/defaults/main.yml similarity index 100% rename from Linux/external-data-mirror/ansible/roles/mirror/defaults/main.yml rename to Linux/external-data-mirror/ansible/roles/mirror-data/defaults/main.yml diff --git a/Linux/external-data-mirror/ansible/roles/mirror/tasks/exchange-keys.yml b/Linux/external-data-mirror/ansible/roles/mirror-data/tasks/exchange-keys.yml similarity index 100% rename from Linux/external-data-mirror/ansible/roles/mirror/tasks/exchange-keys.yml rename to Linux/external-data-mirror/ansible/roles/mirror-data/tasks/exchange-keys.yml diff --git a/Linux/external-data-mirror/ansible/roles/mirror/tasks/main.yml b/Linux/external-data-mirror/ansible/roles/mirror-data/tasks/main.yml similarity index 100% rename from Linux/external-data-mirror/ansible/roles/mirror/tasks/main.yml rename to Linux/external-data-mirror/ansible/roles/mirror-data/tasks/main.yml diff --git a/Linux/external-data-mirror/ansible/roles/mirror/tasks/update-external-data.sh b/Linux/external-data-mirror/ansible/roles/mirror-data/tasks/update-external-data.sh similarity index 100% rename from Linux/external-data-mirror/ansible/roles/mirror/tasks/update-external-data.sh rename to Linux/external-data-mirror/ansible/roles/mirror-data/tasks/update-external-data.sh diff --git a/Linux/external-data-mirror/ansible/roles/server/tasks/main.yml b/Linux/external-data-mirror/ansible/roles/server/tasks/main.yml new file mode 100644 index 0000000..83ce599 --- /dev/null +++ b/Linux/external-data-mirror/ansible/roles/server/tasks/main.yml @@ -0,0 +1,11 @@ +- name: Spin up the nginx docker container to serve the downloaded testing data. + community.docker.docker_container: + name: "nginx-external-data" + image: "nginx:stable" + state: "started" + detach: True + restart_policy: "always" + network_mode: "host" + ports: "80:80" + volumes: + "/external-data/:/usr/share/nginx/html/externaldata/:ro"