nomad/ansible/roles/configure-nomad/tasks/configure.yml
2023-03-18 13:13:16 +00:00

42 lines
808 B
YAML

---
- name: Copy nomad base configuration
become: true
template:
src: nomad-base.hcl.j2
dest: /etc/nomad.d/nomad.hcl
owner: nomad
group: nomad
mode: 0640
- name: Copy nomad-client configuration
become: true
template:
src: nomad-client.hcl
dest: /etc/nomad.d/nomad-client.hcl
owner: nomad
group: nomad
mode: 0640
- name: Copy nomad-server configuration
become: true
template:
src: nomad-server.hcl.j2
dest: /etc/nomad.d/nomad-server.hcl
owner: nomad
group: nomad
mode: 0640
- name: Copy nomad systemd unit file
become: true
template:
src: nomad.service
dest: /etc/systemd/system/nomad.service
owner: root
group: root
mode: 0644
- name: Reload systemd daemon
become: true
systemd:
daemon_reload: true