-
Notifications
You must be signed in to change notification settings - Fork 13
/
build.yaml
34 lines (30 loc) · 985 Bytes
/
build.yaml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
---
- name: compile template files
hosts: local
tasks:
- name: orchestrate basic files
ansible.builtin.template:
src: templates/{{ item.file }}.j2
dest: "{{ playbook_dir }}/{{ item.file }}"
mode: "{{ item.mode }}"
with_items:
- { file: ".env", mode: "a+x" }
- { file: "build-image.sh", mode: "a+x" }
- { file: "download.sh", mode: "a+x" }
- { file: "base-ubuntu-2004/Dockerfile", mode: ~ }
- include_tasks: node-template.yaml
loop:
- name: "hadoop-master1"
group: "hadoop-master"
- name: "hadoop-worker1"
group: "hadoop-worker"
- name: "hadoop-worker2"
group: "hadoop-worker"
- name: "hadoop-worker3"
group: "hadoop-worker"
loop_control:
loop_var: node
- name: orchestrate compose file
ansible.builtin.template:
src: templates/compose.yaml.j2
dest: "{{ playbook_dir }}/compose.yaml"