Skip to content

Commit 8168cc8

Browse files
committed
variable fixes
1 parent 785ec58 commit 8168cc8

File tree

10 files changed

+76
-143
lines changed

10 files changed

+76
-143
lines changed

bkk03

Lines changed: 7 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -17,6 +17,7 @@ bkk00
1717

1818
[polkadot]
1919
dot23
20+
ksm23
2021
wnd23
2122

2223
[cumulus]
@@ -27,14 +28,14 @@ wbr23
2728
pch23
2829
wch23
2930

30-
[proxmox_hosts]
31-
bkk03
32-
3331
[services]
3432
ibp
3533

3634
[unmanaged]
3735

36+
[proxmox_hosts]
37+
bkk03
38+
3839
[hardware]
3940
bkk03
4041

@@ -44,7 +45,6 @@ proxmox_nodes
4445
unmanaged
4546

4647
[referrence_nodes]
47-
dot14
48-
dot24
49-
wnd14
50-
wnd24
48+
monitor
49+
dot26
50+
wnd26

bkk04

Lines changed: 8 additions & 14 deletions
Original file line numberDiff line numberDiff line change
@@ -17,22 +17,16 @@ bkk00
1717
[polkadot]
1818
ksm04
1919
ksm24
20-
; pso24
20+
pso24
2121

2222
[cumulus]
23-
; mine24
24-
; kbr24
25-
; kch24
26-
; pabr24
27-
; pach24
23+
mine24
24+
kbr24
2825

2926
[encointer]
30-
enc14
31-
; enc24
27+
enc24
3228

3329
[services]
34-
ansible
35-
matrix
3630
monitor
3731

3832
[proxmox_hosts]
@@ -49,7 +43,7 @@ proxmox_nodes
4943
unmanaged
5044

5145
[referrence_nodes]
52-
dot14
53-
dot24
54-
wnd14
55-
wnd24
46+
ksm14
47+
ksm24
48+
ksm26
49+
pso26

host_vars/dot24.yaml

Lines changed: 0 additions & 29 deletions
This file was deleted.

host_vars/ksm24.yaml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -18,7 +18,7 @@ default_dotters_repository: "[email protected]:senseless/dotters-ssl"
1818
default_network: kusama
1919
default_node_type: "endpoint"
2020
default_pruning: "archive"
21-
default_database: rocksdb
21+
default_database: paritydb
2222
default_syncmode: full
2323
default_p2p_port: 33324
2424
default_p2p_port_ws: 34324

host_vars/mint26.yaml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -18,7 +18,7 @@ default_node_type: "endpoint"
1818
default_p2p_port: 33616
1919
default_p2p_port_ws: 34616
2020
default_p2p_port_wss: 35616
21-
default_rpc_port: 9716
21+
default_rpc_port: 9616
2222
default_secure_rpc_port: 42616
2323
default_prom_port: 7616
2424
zabbix_ext_port: 10616

host_vars/wnd24.yaml

Lines changed: 0 additions & 29 deletions
This file was deleted.

inventory

Lines changed: 19 additions & 15 deletions
Original file line numberDiff line numberDiff line change
@@ -28,6 +28,14 @@ kbr13
2828
wmint14
2929
wbr13
3030
wch13
31+
mint23
32+
pbr23
33+
pch23
34+
mine24
35+
kbr24
36+
wmint23
37+
wbr23
38+
wch23
3139
mint26
3240
pbr26
3341
pch26
@@ -42,27 +50,23 @@ enc14
4250
enc26
4351

4452
[polkadot]
45-
ksm01
4653
dot01
47-
ksm02
4854
dot02
49-
dot23
50-
ksm23
51-
wnd23
52-
dot26
53-
ksm26
54-
wnd26
55-
dot14
56-
dot24
55+
ksm01
56+
ksm02
5757
ksm04
58+
pso06
59+
dot14
5860
ksm14
59-
ksm24
6061
wnd14
61-
wnd24
62-
pso01
63-
pso02
64-
pso06
6562
pso16
63+
dot23
64+
dot26
65+
ksm23
66+
ksm24
67+
ksm26
68+
wnd23
69+
wnd26
6670
pso26
6771

6872
[proxmox_hosts]
Lines changed: 36 additions & 41 deletions
Original file line numberDiff line numberDiff line change
@@ -1,59 +1,54 @@
1-
# Standards: 0.2
1+
# Standards: 0.2
22
---
33
- name: Create predefined containers
44
community.general.proxmox:
5+
api_user: "{{ api_user }}"
6+
api_password: "{{ api_password }}"
57
api_host: "{{ proxmox_defaults.api_host }}"
6-
api_user: "{{ proxmox_defaults.api_user }}"
7-
api_password: "{{ proxmox_defaults.api_password | default(omit) }}"
8-
api_token_id: "{{ proxmox_defaults.api_token_id | default(omit) }}"
9-
api_token_secret: "{{ proxmox_defaults.api_token_secret | default(omit) }}"
10-
node: "{{ item.proxmox_config.node }}"
11-
password: "{{ item.proxmox_config.password }}"
12-
hostname: "{{ item.proxmox_config.hostname }}"
13-
ostemplate: "{{ item.proxmox_config.ostemplate }}"
14-
disk: "{{ item.proxmox_config.disk | default(omit) }}"
15-
cores: "{{ item.proxmox_config.cores | default(omit) }}"
16-
memory: "{{ item.proxmox_config.memory | default(omit) }}"
17-
swap: "{{ item.proxmox_config.swap | default(omit) }}"
18-
netif: "{{ item.proxmox_config.netif | default(omit) }}"
19-
features: "{{ item.proxmox_config.features | to_json | default(omit) }}"
20-
onboot: "{{ item.proxmox_config.onboot | default(omit) }}"
21-
unprivileged: "{{ item.proxmox_config.unprivileged | default(omit) }}"
228
vmid: "{{ item.proxmox_config.vmid }}"
23-
state: "{{ item.proxmox_config.state | default('present') }}"
9+
hostname: "{{ item.proxmox_config.hostname }}"
10+
template: "{{ item.proxmox_config.ostemplate }}"
11+
netif: "{{ item.proxmox_config.netif }}"
12+
cores: "{{ item.proxmox_config.cores }}"
13+
memory: "{{ item.proxmox_config.memory }}"
14+
swap: "{{ item.proxmox_config.swap }}"
15+
password: "{{ item.proxmox_config.password }}"
16+
disk: "{{ item.proxmox_config.disk }}"
17+
mounts: "{{ item.proxmox_config.mounts }}"
18+
onboot: "{{ item.proxmox_config.onboot }}"
19+
unprivileged: "{{ item.proxmox_config.unprivileged }}"
20+
validate_certs: "{{ item.proxmox_config.validate_certs }}"
21+
description: "{{ item.proxmox_config.description }}"
22+
state: "{{ item.proxmox_config.state }}"
23+
features: "{{ item.proxmox_config.features }}"
2424
loop: "{{ lxc_nodes }}"
2525
when: lxc_nodes is defined
2626
register: container_creation_result
27-
no_log: True # Adjust based on your security policies
2827

29-
- name: Start predefined nodes if not already started
28+
- name: Start predefined nodes
3029
community.general.proxmox:
30+
api_user: "{{ api_user }}"
31+
api_password: "{{ api_password }}"
3132
api_host: "{{ proxmox_defaults.api_host }}"
32-
api_user: "{{ proxmox_defaults.api_user }}"
33-
api_password: "{{ proxmox_defaults.api_password | default(omit) }}"
34-
api_token_id: "{{ proxmox_defaults.api_token_id | default(omit) }}"
35-
api_token_secret: "{{ proxmox_defaults.api_token_secret | default(omit) }}"
36-
node: "{{ item.proxmox_config.node }}"
3733
vmid: "{{ item.proxmox_config.vmid }}"
3834
state: 'started'
3935
loop: "{{ lxc_nodes }}"
4036
when:
4137
- lxc_nodes is defined
42-
- item.proxmox_config.state == 'present'
38+
- "'state' in item.proxmox_config"
39+
- "item.proxmox_config['state'] == 'present'"
4340
register: container_start_result
44-
no_log: True # Adjust based on your security policies
45-
46-
# - name: Create predefined containers
47-
# community.general.proxmox: "{{ proxmox_defaults | combine(item.proxmox_config) }}"
48-
# loop: "{{ lxc_nodes }}"
49-
# when: lxc_nodes is defined
50-
# register: container_creation_result
51-
#
52-
# - name: Start predefined nodes
53-
# community.general.proxmox: "{{ proxmox_defaults | combine({'vmid': item.proxmox_config['vmid'], 'state': 'started'}) }}"
54-
# loop: "{{ lxc_nodes }}"
55-
# when:
56-
# - lxc_nodes is defined
57-
# - item.proxmox_config['state'] == 'present'
58-
# register: container_start_result
5941

42+
# - name: Create predefined containers
43+
# community.general.proxmox: "{{ proxmox_defaults | combine(item.proxmox_config) }}"
44+
# loop: "{{ lxc_nodes }}"
45+
# when: lxc_nodes is defined
46+
# register: container_creation_result
47+
#
48+
# - name: Start predefined nodes
49+
# community.general.proxmox: "{{ proxmox_defaults | combine({'vmid': item.proxmox_config['vmid'], 'state': 'started'}) }}"
50+
# loop: "{{ lxc_nodes }}"
51+
# when:
52+
# - lxc_nodes is defined
53+
# - item.proxmox_config['state'] == 'present'
54+
# register: container_start_result

roles/setup_install_nginx/tasks/main.yaml

Lines changed: 3 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -12,8 +12,9 @@
1212

1313
- name: Check certbot plugins
1414
ansible.builtin.command:
15-
cmd: certbot plugins || true
15+
cmd: certbot plugins
1616
register: certbot_plugins_output
17+
failed_when: False
1718
changed_when: False
1819

1920
- name: Install certbot_dns_porkbun plugin if absent
@@ -34,7 +35,7 @@
3435
-d "{{ default_public_dns }}"
3536
register: certbot_result
3637
changed_when: "'Congratulations' in certbot_result.stdout"
37-
no_log: True
38+
no_log: False
3839

3940
- name: Reload nginx service
4041
ansible.builtin.service:
@@ -111,7 +112,3 @@
111112
dest: "/etc/nginx/sites-enabled/{{ default_public_dns }}"
112113
state: link
113114
notify: Reload nginx
114-
115-
# - name: Include loadbalancer tasks for endpoints
116-
# ansible.builtin.import_tasks: loadbalancer.yaml
117-
# when: default_node_type == 'endpoint'

roles/setup_install_prometheus/tasks/main.yaml

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -19,6 +19,7 @@
1919
cmd: prometheus --version | grep prometheus | awk '{print substr($3, 0, length($3))}'
2020
register: prometheus_installed
2121
changed_when: False
22+
failed_when: False
2223

2324
- name: Import Prometheus tasks
2425
ansible.builtin.import_tasks: "prometheus-tasks.yaml"

0 commit comments

Comments
 (0)