consul config
Some checks failed
Ansible Linting / ansible-lint (push) Failing after 4s
Secops Linting and Safety Checks / checkov-scan-s3 (push) Failing after 15s

This commit is contained in:
shockrah 2025-05-12 01:05:54 -07:00
parent 9785e8a40a
commit 4851b6521c
2 changed files with 23 additions and 0 deletions

View File

@ -0,0 +1,10 @@
bind_addr = "{{ GetInterfaceIP 'eno1' }}"
advertise_addr = "{{ GetInterfaceIP 'eno1' }}"
client_addr = "{{ GetInterfaceIP 'eno1' }}"
server = true
data_dir = "/opt/consul"
ui_config {
enabled = true
}

View File

@ -29,9 +29,22 @@
- name: Update apt repo cache
ansible.builtin.apt:
update_cache: true
- name: Install consul
ansible.builtin.apt:
name: consul
- name: Install nomad package
ansible.builtin.apt:
pkg: nomad
- name: Copy in the consul configuration
ansible.builtin.copy:
src: consul.hcl
dest: /etc/consul.d/consul.hcl
mode: "0644"
- name: Start consul
ansible.builtin.systemd_service:
name: nomad
state: started
enabled: true
- name: Make sure the nomad service is available
ansible.builtin.systemd_service:
name: nomad