first pass at incorporating mesh setup/config

This commit is contained in:
Lee Goolsbee
2024-03-25 12:55:28 -05:00
parent 1c461004c3
commit a902044657
20 changed files with 1301 additions and 580 deletions

View File

@@ -0,0 +1,12 @@
---
# we just want to set the node.name for now, other values will get auto populated as the mesh node connects
# this may need to be expanded later, but don't add node.id unless you get it from bitbucket primary cluster
# first see if it's already set - if it is, use that, else generate a random one
- name: set mesh_node_name var from the existing mesh.properties file
ansible.builtin.set_fact:
mesh_node_name: "{{ lookup('ansible.builtin.ini', 'node.name type=properties file=mesh_properties_file') | split('.') | first }}"
- name: generate a pet name if mesh_node_name is empty or this is a clone firstrun # noqa jinja[invalid]
ansible.builtin.set_fact:
mesh_node_name: "{{ lookup('community.general.random_pet', words=3) }}"