Skip to content

Commit 8b7b243

Browse files
committed
Refactor multinode firewall config
1 parent 7319952 commit 8b7b243

File tree

8 files changed

+162
-36
lines changed

8 files changed

+162
-36
lines changed

etc/kayobe/environments/ci-multinode/compute.yml

Lines changed: 23 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -4,3 +4,26 @@ compute_bootstrap_user: "{{ os_distribution if os_distribution == 'ubuntu' else
44
# format.
55
compute_lvm_groups:
66
- "{{ stackhpc_lvm_group_rootvg }}"
7+
8+
###############################################################################
9+
# Compute node firewalld configuration.
10+
11+
# Whether to install and enable firewalld.
12+
compute_firewalld_enabled: true
13+
14+
# A list of zones to create. Each item is a dict containing a 'zone' item.
15+
compute_firewalld_zones: "{{ stackhpc_firewalld_zones }}"
16+
17+
# A firewalld zone to set as the default. Default is unset, in which case
18+
# the default zone will not be changed.
19+
# Predefined zones are listed here:
20+
# https://firewalld.org/documentation/zone/predefined-zones.html
21+
compute_firewalld_default_zone: trusted
22+
23+
# A list of firewall rules to apply. Each item is a dict containing
24+
# arguments to pass to the firewalld module. Arguments are omitted if not
25+
# provided, with the following exceptions:
26+
# - offline: true
27+
# - permanent: true
28+
# - state: enabled
29+
compute_firewalld_rules: "{{ stackhpc_firewalld_rules }}"

etc/kayobe/environments/ci-multinode/controllers.yml

Lines changed: 24 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -4,3 +4,27 @@ controller_bootstrap_user: "{{ os_distribution if os_distribution == 'ubuntu' el
44
# format.
55
controller_lvm_groups:
66
- "{{ stackhpc_lvm_group_rootvg }}"
7+
8+
9+
###############################################################################
10+
# Controller node firewalld configuration.
11+
12+
# Whether to install and enable firewalld.
13+
controller_firewalld_enabled: true
14+
15+
# A list of zones to create. Each item is a dict containing a 'zone' item.
16+
controller_firewalld_zones: "{{ stackhpc_firewalld_zones }}"
17+
18+
# A firewalld zone to set as the default. Default is unset, in which case
19+
# the default zone will not be changed.
20+
# Predefined zones are listed here:
21+
# https://firewalld.org/documentation/zone/predefined-zones.html
22+
controller_firewalld_default_zone: trusted
23+
24+
# A list of firewall rules to apply. Each item is a dict containing
25+
# arguments to pass to the firewalld module. Arguments are omitted if not
26+
# provided, with the following exceptions:
27+
# - offline: true
28+
# - permanent: true
29+
# - state: enabled
30+
controller_firewalld_rules: "{{ stackhpc_firewalld_rules }}"

etc/kayobe/environments/ci-multinode/firewalld.yml

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

etc/kayobe/environments/ci-multinode/infra-vms.yml

Lines changed: 23 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -4,3 +4,26 @@ infra_vm_bootstrap_user: "{{ os_distribution if os_distribution == 'ubuntu' else
44
# format.
55
infra_vm_lvm_groups:
66
- "{{ stackhpc_lvm_group_rootvg }}"
7+
8+
###############################################################################
9+
# Infrastructure VM node firewalld configuration
10+
11+
# Whether to install and enable firewalld.
12+
infra_vm_firewalld_enabled: true
13+
14+
# A list of zones to create. Each item is a dict containing a 'zone' item.
15+
infra_vm_firewalld_zones: "{{ stackhpc_firewalld_zones }}"
16+
17+
# A firewalld zone to set as the default. Default is unset, in which case
18+
# the default zone will not be changed.
19+
# Predefined zones are listed here:
20+
# https://firewalld.org/documentation/zone/predefined-zones.html
21+
infra_vm_firewalld_default_zone: trusted
22+
23+
# A list of firewall rules to apply. Each item is a dict containing
24+
# arguments to pass to the firewalld module. Arguments are omitted if not
25+
# provided, with the following exceptions:
26+
# - offline: true
27+
# - permanent: true
28+
# - state: enabled
29+
infra_vm_firewalld_rules: "{{ stackhpc_firewalld_rules }}"
Lines changed: 23 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,23 @@
1+
---
2+
###############################################################################
3+
# monitoring node firewalld configuration.
4+
5+
# Whether to install and enable firewalld.
6+
monitoring_firewalld_enabled: true
7+
8+
# A list of zones to create. Each item is a dict containing a 'zone' item.
9+
monitoring_firewalld_zones: "{{ stackhpc_firewalld_zones }}"
10+
11+
# A firewalld zone to set as the default. Default is unset, in which case
12+
# the default zone will not be changed.
13+
# Predefined zones are listed here:
14+
# https://firewalld.org/documentation/zone/predefined-zones.html
15+
monitoring_firewalld_default_zone: trusted
16+
17+
# A list of firewall rules to apply. Each item is a dict containing
18+
# arguments to pass to the firewalld module. Arguments are omitted if not
19+
# provided, with the following exceptions:
20+
# - offline: true
21+
# - permanent: true
22+
# - state: enabled
23+
monitoring_firewalld_rules: "{{ stackhpc_firewalld_rules }}"
Lines changed: 23 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,23 @@
1+
---
2+
###############################################################################
3+
# seed_hypervisor node firewalld configuration.
4+
5+
# Whether to install and enable firewalld.
6+
seed_hypervisor_firewalld_enabled: true
7+
8+
# A list of zones to create. Each item is a dict containing a 'zone' item.
9+
seed_hypervisor_firewalld_zones: "{{ stackhpc_firewalld_zones }}"
10+
11+
# A firewalld zone to set as the default. Default is unset, in which case
12+
# the default zone will not be changed.
13+
# Predefined zones are listed here:
14+
# https://firewalld.org/documentation/zone/predefined-zones.html
15+
seed_hypervisor_firewalld_default_zone: trusted
16+
17+
# A list of firewall rules to apply. Each item is a dict containing
18+
# arguments to pass to the firewalld module. Arguments are omitted if not
19+
# provided, with the following exceptions:
20+
# - offline: true
21+
# - permanent: true
22+
# - state: enabled
23+
seed_hypervisor_firewalld_rules: "{{ stackhpc_firewalld_rules }}"

etc/kayobe/environments/ci-multinode/seed.yml

Lines changed: 23 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -27,3 +27,26 @@ snat_rules_manila:
2727
source_ip: "{{ ansible_facts[storage_interface].ipv4.address | default }}"
2828
# Only add the storage snat rule if we are using manila-cephfs.
2929
snat_rules: "{{ snat_rules_default + snat_rules_manila if (kolla_enable_manila | bool and kolla_enable_manila_backend_cephfs_native | bool) else snat_rules_default }}"
30+
31+
###############################################################################
32+
# seed node firewalld configuration.
33+
34+
# Whether to install and enable firewalld.
35+
seed_firewalld_enabled: true
36+
37+
# A list of zones to create. Each item is a dict containing a 'zone' item.
38+
seed_firewalld_zones: "{{ stackhpc_firewalld_zones }}"
39+
40+
# A firewalld zone to set as the default. Default is unset, in which case
41+
# the default zone will not be changed.
42+
# Predefined zones are listed here:
43+
# https://firewalld.org/documentation/zone/predefined-zones.html
44+
seed_firewalld_default_zone: trusted
45+
46+
# A list of firewall rules to apply. Each item is a dict containing
47+
# arguments to pass to the firewalld module. Arguments are omitted if not
48+
# provided, with the following exceptions:
49+
# - offline: true
50+
# - permanent: true
51+
# - state: enabled
52+
seed_firewalld_rules: "{{ stackhpc_firewalld_rules }}"

etc/kayobe/environments/ci-multinode/storage.yml

Lines changed: 23 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -4,3 +4,26 @@ storage_bootstrap_user: "{{ os_distribution if os_distribution == 'ubuntu' else
44
# format.
55
storage_lvm_groups:
66
- "{{ stackhpc_lvm_group_rootvg }}"
7+
8+
###############################################################################
9+
# storage node firewalld configuration.
10+
11+
# Whether to install and enable firewalld.
12+
storage_firewalld_enabled: true
13+
14+
# A list of zones to create. Each item is a dict containing a 'zone' item.
15+
storage_firewalld_zones: "{{ stackhpc_firewalld_zones }}"
16+
17+
# A firewalld zone to set as the default. Default is unset, in which case
18+
# the default zone will not be changed.
19+
# Predefined zones are listed here:
20+
# https://firewalld.org/documentation/zone/predefined-zones.html
21+
storage_firewalld_default_zone: trusted
22+
23+
# A list of firewall rules to apply. Each item is a dict containing
24+
# arguments to pass to the firewalld module. Arguments are omitted if not
25+
# provided, with the following exceptions:
26+
# - offline: true
27+
# - permanent: true
28+
# - state: enabled
29+
storage_firewalld_rules: "{{ stackhpc_firewalld_rules }}"

0 commit comments

Comments
 (0)