community.general.dladm_iptun (0.1.1) — module

Manage IP tunnel interfaces on Solaris/illumos systems.

Authors: Adam Števko (@xen0l)

preview | supported by community

Install collection

Install with ansible-galaxy collection install community.general:==0.1.1


Add to requirements.yml

  collections:
    - name: community.general
      version: 0.1.1

Description

Manage IP tunnel interfaces on Solaris/illumos systems.

Usage examples

  • Success
    Steampunk Spotter scan finished with no errors, warnings or hints.
- name: Create IPv4 tunnel interface 'iptun0'
  dladm_iptun: name=iptun0 local_address=192.0.2.23 remote_address=203.0.113.10 state=present
  • Success
    Steampunk Spotter scan finished with no errors, warnings or hints.
- name: Change IPv4 tunnel remote address
  dladm_iptun: name=iptun0 type=ipv4 local_address=192.0.2.23 remote_address=203.0.113.11
  • Success
    Steampunk Spotter scan finished with no errors, warnings or hints.
- name: Create IPv6 tunnel interface 'tun0'
  dladm_iptun: name=tun0 type=ipv6 local_address=192.0.2.23 remote_address=203.0.113.42
  • Success
    Steampunk Spotter scan finished with no errors, warnings or hints.
- name: Remove 'iptun0' tunnel interface
  dladm_iptun: name=iptun0 state=absent

Inputs

    
name:
    description:
    - IP tunnel interface name.
    required: true

type:
    aliases:
    - tunnel_type
    choices:
    - ipv4
    - ipv6
    - 6to4
    default: ipv4
    description:
    - Specifies the type of tunnel to be created.
    required: false

state:
    choices:
    - present
    - absent
    default: present
    description:
    - Create or delete Solaris/illumos VNIC.
    required: false

temporary:
    default: false
    description:
    - Specifies that the IP tunnel interface is temporary. Temporary IP tunnel interfaces
      do not persist across reboots.
    required: false
    type: bool

local_address:
    aliases:
    - local
    description:
    - Literal IP address or hostname corresponding to the tunnel source.
    required: false

remote_address:
    aliases:
    - remote
    description:
    - Literal IP address or hostname corresponding to the tunnel destination.
    required: false

Outputs

local_address:
  description: local IP address
  returned: always
  sample: 1.1.1.1/32
  type: str
name:
  description: tunnel interface name
  returned: always
  sample: iptun0
  type: str
remote_address:
  description: remote IP address
  returned: always
  sample: 2.2.2.2/32
  type: str
state:
  description: state of the target
  returned: always
  sample: present
  type: str
temporary:
  description: specifies if operation will persist across reboots
  returned: always
  sample: true
  type: bool
type:
  description: tunnel type
  returned: always
  sample: ipv4
  type: str