damex.incus.incus_network_zones role – Ensure Incus network zones.

Note

This role is part of the damex.incus collection (version 1.9.0).

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 damex.incus.

To use it in a playbook, specify: damex.incus.incus_network_zones.

Entry point main – Ensure Incus network zones.

Synopsis

  • Ensure Incus network zones.

Parameters

Parameter

Comments

incus_network_zones

list / elements=dictionary

List of Incus network zones to ensure.

config

dictionary

Zone configuration key-value pairs (user.* keys only).

description

string

Description of the network zone.

name

string / required

Name of the network zone.

project

string

Incus project for the network zone.

state

string

Desired state of the network zone.

Choices:

  • "present"

  • "absent"

incus_network_zones_client_cert

string

Client certificate content for API authentication.

incus_network_zones_client_cert_path

path

Path to the TLS client certificate for API authentication.

incus_network_zones_client_key

string

Client key content for API authentication.

incus_network_zones_client_key_path

path

Path to the TLS client key for API authentication.

incus_network_zones_project

string

Default Incus project for network zones.

incus_network_zones_server_cert

string

Server certificate content for API verification.

incus_network_zones_server_cert_path

path

Path to the TLS server certificate for API verification.

incus_network_zones_socket_path

path

Path to the Incus Unix socket.

incus_network_zones_state

string

Default desired state of the network zones.

Choices:

  • "present"

  • "absent"

incus_network_zones_token

string

Authentication token for the Incus API.

incus_network_zones_url

string

URL of the Incus server API.

incus_network_zones_validate_certs

boolean

Whether to validate TLS certificates.

Choices:

  • false

  • true

Examples

- name: Ensure incus network zones
  hosts: incus
  tasks:
    - name: Ensure incus network zones
      ansible.builtin.import_role:
        name: damex.incus.incus_network_zones
      vars:
        incus_network_zones:
          - name: example.com
            description: Forward DNS zone
          - name: internal.lan
            config:
              user.note: Internal zone