nomad/ansible/roles/configure-consul/tasks/configure.yml
2023-03-15 00:19:55 +00:00

33 lines
No EOL
634 B
YAML
Executable file

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