task name, comments, and other general formatting updates

This commit is contained in:
Lee Goolsbee
2024-03-26 14:54:39 -05:00
parent b0824a858c
commit 6881bc1a89
12 changed files with 92 additions and 93 deletions

View File

@@ -1,25 +1,25 @@
---
# update mesh.properties with the mesh_node_name from the tag in mesh_vol_info
- name: enforce node.name per volume tag
- name: Update mesh.properties 'node.name' with mesh_node_name value
ansible.builtin.lineinfile:
line: node.name={{ mesh_node_name }}
path: "{{ mesh_properties_file }}"
regexp: '^node\.name='
- name: enforce node.rpc-url per node_name
- name: Update mesh.properties 'node.rpc-url' with mesh_node_name value
ansible.builtin.lineinfile:
path: "{{ mesh_properties_file }}"
search_string: 'node.rpc-url='
line: node.rpc-url={{ mesh_node_scheme }}://{{ mesh_node_name }}.{{ atl_aws_stack_name }}-{{ ansible_ec2_placement_region }}.{{ atl_hostedzone }}:{{ mesh_node_port }}
- name: enforce metrics.tags.host per volume tag
- name: Update mesh.properties 'metrics.tags.host' with mesh_node_name value
ansible.builtin.lineinfile:
path: "{{ mesh_properties_file }}"
search_string: 'metrics.tags.host='
line: metrics.tags.host={{ mesh_node_name }}
# the idea here is that the pet name will persist through clones, and just the stack_name - region part of the url will change (and maybe the hosted zone)
- name: create r53 entry for this mesh node based on the mesh_node_name
- name: Create Route 53 entry for this mesh node based on the mesh_node_name
amazon.aws.route53:
command: create
zone: "{{ atl_hostedzone }}"
@@ -34,7 +34,7 @@
- mesh_vol is regex('^vol-.*')
tags: notest # doesn't work in molecule
- name: build a dict of tags from the ec2 instance to apply to the ebs volume
- name: Build a dict of tags from the EC2 instance to apply to the EBS volume
ansible.builtin.set_fact:
ebs_tags: "{{ ebs_tags | default({}) | combine({item.key: item.value}) }}"
when:
@@ -42,7 +42,7 @@
- item.key is not match("aws:.*")
with_dict: "{{ ec2_instance_tags.tags }}"
- name: apply the tags from the ec2 instance to the ebs volume
- name: Apply the tags from the EC2 instance to the EBS volume
amazon.aws.ec2_tag:
region: "{{ ansible_ec2_placement_region }}"
resource: "{{ ((mesh_vol is defined) and (mesh_vol | length > 0)) | ternary(mesh_vol, mesh_vol_info.volume.id) }}"
@@ -51,7 +51,7 @@
purge_tags: false
tags: notest # doesn't work in molecule
- name: add the mesh_node_name tag to the ebs volume and current ec2
- name: Add the mesh_node_name tag to the EBS volume and current EC2
amazon.aws.ec2_tag:
region: "{{ ansible_ec2_placement_region }}"
resource: "{{ item }}"