puzzle.opnsense.interfaces_assignments module – This module can be used to assign interfaces to network ports and network IDs to new interfaces.

Note

This module is part of the puzzle.opnsense collection (version 1.5.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 puzzle.opnsense.

To use it in a playbook, specify: puzzle.opnsense.interfaces_assignments.

New in puzzle.opnsense 1.1.0

Synopsis

  • Module to assign interfaces to network ports and network IDs to new interfaces.

Parameters

Parameter

Comments

description

string

Interface name shown in the GUI. Identifier in capital letters if not provided.

Input will be trimmed, as no whitespaces are allowed.

device

string / required

Physical Device Name eg. vtnet0, ipsec1000 etc,.

identifier

string / required

Technical identifier of the interface, used by hasync for example

Examples

- name: Assign Vagrant interface to device em4
  puzzle.opnsense.interfaces_assignments:
    identifier: "VAGRANT"
    device: "em4"

- name: Create new assignment
  puzzle.opnsense.interfaces_assignments:
    identifier: "lan"
    device: "vtnet1"
    description: "lan_interface"

Return Values

Common return values are documented here, the following are the fields unique to this module:

Key

Description

opnsense_configure_output

list / elements=string

A list of the executed OPNsense configure function along with their respective stdout, stderr and rc

Returned: always

Sample: [{"function": "filter_configure", "params": ["true"], "rc": 0, "stderr": "", "stderr_lines": [], "stdout": "", "stdout_lines": []}, {"function": "rrd_configure", "params": ["true"], "rc": 0, "stderr": "", "stderr_lines": [], "stdout": "Generating RRD graphs...done.", "stdout_lines": ["Generating RRD graphs...done."]}]

Authors

  • Kilian Soltermann (@killuuuhh)