Concluding the testing of the Geth role
This commit is contained in:
+25
-23
@@ -100,40 +100,42 @@ all:
|
||||
ups: 'apc'
|
||||
active_vms:
|
||||
- Yggdrasil
|
||||
Geth:
|
||||
vars:
|
||||
geth_primary: Geth1
|
||||
pitest:
|
||||
hosts:
|
||||
Geth0:
|
||||
ipinterface: eth0
|
||||
ip: 10.0.1.9
|
||||
mac: b8:27:eb:09:a1:a0
|
||||
static: true
|
||||
Geth5:
|
||||
ipinterface: eth0
|
||||
ip: 10.0.1.14
|
||||
mac: b8:27:eb:81:f5:4b
|
||||
static: true
|
||||
Geth:
|
||||
vars:
|
||||
geth_primary: Geth1
|
||||
hosts:
|
||||
Geth1:
|
||||
ipinterface: eth0
|
||||
ip: 10.0.1.10
|
||||
mac: e4:5f:01:01:ff:d5
|
||||
static: true
|
||||
# Geth2:
|
||||
# ipinterface: eth0
|
||||
# ip: 10.0.1.11
|
||||
# mac: e4:5f:01:01:ff:9c
|
||||
# static: true
|
||||
# Geth3:
|
||||
# ipinterface: eth0
|
||||
# ip: 10.0.1.12
|
||||
# mac: e4:5f:01:01:ff:96
|
||||
# static: true
|
||||
# Geth4:
|
||||
# ipinterface: eth0
|
||||
# ip: 10.0.1.13
|
||||
# mac: e4:5f:01:01:ff:e4
|
||||
# static: true
|
||||
# Geth5:
|
||||
# ipinterface: eth0
|
||||
# ip: 10.0.1.14
|
||||
# mac: b8:27:eb:81:f5:4b
|
||||
# static: true
|
||||
Geth2:
|
||||
ipinterface: eth0
|
||||
ip: 10.0.1.11
|
||||
mac: e4:5f:01:01:ff:9c
|
||||
static: true
|
||||
Geth3:
|
||||
ipinterface: eth0
|
||||
ip: 10.0.1.12
|
||||
mac: e4:5f:01:01:ff:96
|
||||
static: true
|
||||
Geth4:
|
||||
ipinterface: eth0
|
||||
ip: 10.0.1.13
|
||||
mac: e4:5f:01:01:ff:e4
|
||||
static: true
|
||||
virtual: # 10.0.1.16/28
|
||||
vars:
|
||||
hosts:
|
||||
|
||||
@@ -14,6 +14,3 @@
|
||||
- name: Worker tasks
|
||||
include_tasks: worker.yml
|
||||
when: "not inventory_hostname == geth_primary"
|
||||
|
||||
- name: Service tasks
|
||||
include_tasks: services.yml
|
||||
|
||||
@@ -15,3 +15,10 @@
|
||||
- name: Ensure the token is in vault
|
||||
assert:
|
||||
that: k3s_token_cat.stdout_lines[0] is in secrets['Geth']['k3s_token']
|
||||
|
||||
- name: Enable k3s
|
||||
become: yes
|
||||
ansible.builtin.service:
|
||||
name: k3s
|
||||
state: restarted
|
||||
enabled: yes
|
||||
|
||||
@@ -1,8 +0,0 @@
|
||||
---
|
||||
|
||||
- name: Enable k3s
|
||||
become: yes
|
||||
ansible.builtin.service:
|
||||
name: k3s
|
||||
state: restarted
|
||||
enabled: yes
|
||||
@@ -1,7 +1,14 @@
|
||||
---
|
||||
|
||||
- name: Set up primary
|
||||
- name: Set up worker
|
||||
become: yes
|
||||
ansible.builtin.command:
|
||||
cmd: '/bin/bash -c "K3S_TOKEN={{ secrets['Geth']['k3s_token'] }} K3S_URL=https://{{ geth_primary }}:6443 K3S_NODE_NAME=${HOSTNAME} /usr/local/sbin/get-k3s.sh"'
|
||||
creates: /etc/systemd/system/k3s.service
|
||||
cmd: /bin/bash -c "K3S_TOKEN={{ secrets['Geth']['k3s_token'] }} K3S_URL=https://{{ geth_primary }}:6443 K3S_NODE_NAME=${HOSTNAME} /usr/local/sbin/get-k3s.sh"
|
||||
creates: /etc/systemd/system/k3s-agent.service
|
||||
|
||||
- name: Enable k3s-agent
|
||||
become: yes
|
||||
ansible.builtin.service:
|
||||
name: k3s-agent
|
||||
state: restarted
|
||||
enabled: yes
|
||||
|
||||
Reference in New Issue
Block a user