aboutsummaryrefslogtreecommitdiffstats
path: root/resources/tools/testbed-setup/ansible/roles/consul/templates/services.json.j2
diff options
context:
space:
mode:
authorpmikus <pmikus@cisco.com>2020-11-23 13:56:20 +0000
committerPeter Mikus <pmikus@cisco.com>2020-11-26 09:49:52 +0000
commit37337e09e81af58459d8029b00ca50d0f8d5897a (patch)
tree170bdebd379af1b1f3cdfc086c073dde8d81951a /resources/tools/testbed-setup/ansible/roles/consul/templates/services.json.j2
parent610e96a2afae5c8e58bee00d05c45d57d7bb6021 (diff)
Ansible: Hashicorp Consul
Signed-off-by: pmikus <pmikus@cisco.com> Change-Id: I56987d744d9143a95954d85f2557cda07220c681
Diffstat (limited to 'resources/tools/testbed-setup/ansible/roles/consul/templates/services.json.j2')
-rw-r--r--resources/tools/testbed-setup/ansible/roles/consul/templates/services.json.j213
1 files changed, 13 insertions, 0 deletions
diff --git a/resources/tools/testbed-setup/ansible/roles/consul/templates/services.json.j2 b/resources/tools/testbed-setup/ansible/roles/consul/templates/services.json.j2
new file mode 100644
index 0000000000..3245ba92a4
--- /dev/null
+++ b/resources/tools/testbed-setup/ansible/roles/consul/templates/services.json.j2
@@ -0,0 +1,13 @@
+{
+ "services": [
+{% for item in consul_services %}
+ {
+ "name": "{{ item.name }}",
+ "port": {{ item.port }}
+ }
+{%- if not loop.last %},
+{% endif %}
+{% endfor %}
+
+ ]
+} \ No newline at end of file