@@ -239,6 +239,9 @@ API network:
239
239
enable_external_api_firewalld : true
240
240
external_api_firewalld_zone : " {{ public_net_name | net_zone }}"
241
241
242
+ Network configuration
243
+ ---------------------
244
+
242
245
Ensure every network in ``networks.yml `` has a zone defined. The standard
243
246
configuration is to set the internal network zone to ``trusted `` and every
244
247
other zone to the name of the network. See
@@ -253,20 +256,29 @@ The variable is a list of firewall rules to apply. Each item is a dictionary
253
256
containing arguments to pass to the firewalld module. The variable can be
254
257
defined as a group var or host var in the kayobe inventory.
255
258
256
- The example below would enable SSH on the ``provision_oc `` network, and disable
257
- UDP port 1000 on the ``admin_oc `` network for the Wazuh manager Infrastructure
259
+ The structure of custom rules is different from the default rules. Custom rules
260
+ use the firewalld Ansible module format. Arguments are omitted if not provided,
261
+ with the following exceptions:
262
+
263
+ * ``offline: true ``
264
+ * ``permanent: true ``
265
+ * ``state: enabled ``
266
+
267
+ The main differences are that the ``zone `` argument is mandatory, and the
268
+ ``network `` argument is not.
269
+
270
+ The example below would enable SSH in the ``provision_oc `` zone, and disable
271
+ UDP port 1000 in the ``admin_oc `` zone for the Wazuh manager Infrastructure
258
272
VM:
259
273
260
274
.. code-block :: yaml
261
275
:caption : ` ` etc/kayobe/inventory/group_vars/wazuh_manager/firewall``
262
276
263
277
stackhpc_firewalld_rules_extra :
264
278
- service : ssh
265
- network : " {{ provision_oc_net_name }}"
266
279
zone : " {{ provision_oc_net_name | net_zone }}"
267
280
state : enabled
268
281
- port : 1000/udp
269
- network : " {{ admin_oc_net_name }}"
270
282
zone : " {{ admin_oc_net_name | net_zone }}"
271
283
state : disabled
272
284
@@ -275,23 +287,6 @@ validated before being applied. Use with caution. If you need to add a custom
275
287
rule, consider adding it to the default rule list with an appropriate boolean
276
288
condition, and where possible merge your changes back into upstream SKC.
277
289
278
- Kolla-Ansible configuration
279
- ---------------------------
280
-
281
- Ensure Kolla Ansible opens up ports in firewalld for services on the public
282
- API network:
283
-
284
- .. code-block :: yaml
285
- :caption : ` ` etc/kayobe/kolla/globals.yml``
286
-
287
- enable_external_api_firewalld : true
288
- external_api_firewalld_zone : " {{ public_net_name | net_zone }}"
289
-
290
- Ensure every network in ``networks.yml `` has a zone defined. The standard
291
- configuration is to set the internal network zone to ``trusted `` and every
292
- other zone to the name of the network. See
293
- ``etc/kayobe/environments/ci-multinode/networks.yml `` for a practical example.
294
-
295
290
Validation
296
291
----------
297
292
0 commit comments