From ce18650e1f87983390fe681891c7ecfc5f10e1df Mon Sep 17 00:00:00 2001 From: Ian Fijolek Date: Fri, 17 Jun 2022 15:19:43 -0700 Subject: [PATCH] Add base hostname to consul in Playbook --- nomad/setup-cluster.yml | 7 +++++++ 1 file changed, 7 insertions(+) diff --git a/nomad/setup-cluster.yml b/nomad/setup-cluster.yml index 2c3d81d..3ad2934 100644 --- a/nomad/setup-cluster.yml +++ b/nomad/setup-cluster.yml @@ -55,6 +55,13 @@ key: ansible_test value: Hello from Ansible! + - name: Set hostname + consul_kv: + host: "{{ inventory_hostname }}" + key: global/base_hostname + # TODO: propogate this through via Consul and Nomad templates rather than Terraform + value: dev.homelab + delegate_to: localhost run_once: true