community.general.awall module – Manage awall policies

Note

This module is part of the community.general collection (version 8.6.8).

You might already have this collection installed if you are using the ansible package. It is not included in ansible-core. To check whether it is installed, run ansible-galaxy collection list.

To install it, use: ansible-galaxy collection install community.general.

To use it in a playbook, specify: community.general.awall.

Synopsis

  • This modules allows for enable/disable/activate of awall policies.

  • Alpine Wall (awall) generates a firewall configuration from the enabled policy files and activates the configuration on the system.

Aliases: system.awall

Parameters

Parameter

Comments

activate

boolean

Activate the new firewall rules.

Can be run with other steps or on its own.

Idempotency is affected if activate=true, as the module will always report a changed state.

Choices:

  • false ← (default)

  • true

name

list / elements=string

One or more policy names.

state

string

Whether the policies should be enabled or disabled.

Choices:

  • "disabled"

  • "enabled" ← (default)

Attributes

Attribute

Support

Description

check_mode

Support: full

Can run in check_mode and return changed status prediction without modifying target.

diff_mode

Support: none

Will return details on what has changed (or possibly needs changing in check_mode), when in diff mode.

Notes

Note

Examples

- name: Enable "foo" and "bar" policy
  community.general.awall:
    name: [ foo bar ]
    state: enabled

- name: Disable "foo" and "bar" policy and activate new rules
  community.general.awall:
    name:
    - foo
    - bar
    state: disabled
    activate: false

- name: Activate currently enabled firewall rules
  community.general.awall:
    activate: true

Authors

  • Ted Trask (@tdtrask)