community.general.pn_stp (0.1.1) — module

CLI command to modify stp

Authors: Pluribus Networks (@rajaspachipulusu17)

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

This module can be used to modify Spanning Tree Protocol parameters.

Usage examples

  • Success
    Steampunk Spotter scan finished with no errors, warnings or hints.
- name: Modify stp
  pn_stp:
    pn_cliswitch: "sw01"
    state: "update"
    pn_hello_time: "3"
    pn_stp_mode: "rstp"

Inputs

    
state:
    choices:
    - update
    description:
    - State the action to perform. Use C(update) to stp.
    required: true
    type: str

pn_enable:
    description:
    - enable or disable STP
    type: bool

pn_max_age:
    default: '20'
    description:
    - maximum age time between 6 and 40 secs.
    type: str

pn_stp_mode:
    choices:
    - rstp
    - mstp
    description:
    - STP mode.
    type: str

pn_bridge_id:
    description:
    - STP bridge id.
    type: str

pn_cliswitch:
    description:
    - Target switch to run the CLI on.
    required: false
    type: str

pn_hello_time:
    default: '2'
    description:
    - STP hello time between 1 and 10 secs.
    type: str

pn_mst_max_hops:
    default: '20'
    description:
    - maximum hop count for mstp bpdu.
    type: str

pn_bridge_priority:
    default: '32768'
    description:
    - STP bridge priority.
    type: str

pn_mst_config_name:
    description:
    - Name for MST Configuration Instance.
    type: str

pn_forwarding_delay:
    default: '15'
    description:
    - STP forwarding delay between 4 and 30 secs.
    type: str

pn_bpdus_bridge_ports:
    description:
    - BPDU packets to bridge specific port.
    type: bool

pn_root_guard_wait_time:
    default: '20'
    description:
    - root guard wait time between 0 and 300 secs. 0 to disable wait.
    type: str

Outputs

changed:
  description: indicates whether the CLI caused changes on the target.
  returned: always
  type: bool
command:
  description: the CLI command run on the target node.
  returned: always
  type: str
stderr:
  description: set of error responses from the stp command.
  returned: on error
  type: list
stdout:
  description: set of responses from the stp command.
  returned: always
  type: list