damex.incus.incus_network_address_sets role – Ensure Incus network address sets.

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_address_sets.

Entry point main – Ensure Incus network address sets.

Synopsis

  • Ensure Incus network address sets.

Parameters

Parameter

Comments

incus_network_address_sets

list / elements=dictionary

List of Incus network address sets to ensure.

addresses

list / elements=string

List of IPv4 or IPv6 addresses, with or without CIDR suffix.

config

dictionary

Network address set configuration key-value pairs.

description

string

Description of the network address set.

name

string / required

Name of the network address set.

project

string

Incus project for the network address set.

state

string

Desired state of the network address set.

Choices:

  • "present"

  • "absent"

incus_network_address_sets_client_cert

string

Client certificate content for API authentication.

incus_network_address_sets_client_cert_path

path

Path to the TLS client certificate for API authentication.

incus_network_address_sets_client_key

string

Client key content for API authentication.

incus_network_address_sets_client_key_path

path

Path to the TLS client key for API authentication.

incus_network_address_sets_project

string

Default Incus project for network address sets.

incus_network_address_sets_server_cert

string

Server certificate content for API verification.

incus_network_address_sets_server_cert_path

path

Path to the TLS server certificate for API verification.

incus_network_address_sets_socket_path

path

Path to the Incus Unix socket.

incus_network_address_sets_state

string

Default desired state of the network address sets.

Choices:

  • "present"

  • "absent"

incus_network_address_sets_token

string

Authentication token for the Incus API.

incus_network_address_sets_url

string

URL of the Incus server API.

incus_network_address_sets_validate_certs

boolean

Whether to validate TLS certificates.

Choices:

  • false

  • true

Examples

- name: Ensure incus network address sets
  hosts: incus
  tasks:
    - name: Ensure incus network address sets
      ansible.builtin.import_role:
        name: damex.incus.incus_network_address_sets
      vars:
        incus_network_address_sets:
          - name: web_servers
            description: Web server addresses
            addresses:
              - 10.0.0.5
              - 10.0.0.6
          - name: dns_servers
            addresses:
              - 10.0.0.10
              - 2001:db8::1