�
�Udac @` s� d d l m Z m Z m Z e Z i d d 6d g d 6d d 6Z d Z d Z d
Z d d l
m Z d d l m
Z
m Z m Z d
� Z e d k r� e � n d S( i ( t absolute_importt divisiont print_functions 1.1t metadata_versiont previewt statust communityt supported_bys
---
module: pn_igmp_snooping
author: "Pluribus Networks (@rajaspachipulusu17)"
version_added: "2.8"
short_description: CLI command to modify igmp-snooping
description:
- This module can be used to modify Internet Group Management Protocol (IGMP) snooping.
options:
pn_cliswitch:
description:
- Target switch to run the CLI on.
required: False
type: str
state:
description:
- State the action to perform. Use C(update) to modify the igmp-snooping.
required: True
type: str
choices: ['update']
pn_enable:
description:
- enable or disable IGMP snooping.
required: False
type: bool
pn_query_interval:
description:
- IGMP query interval in seconds.
required: False
type: str
pn_igmpv2_vlans:
description:
- VLANs on which to use IGMPv2 protocol.
required: False
type: str
pn_igmpv3_vlans:
description:
- VLANs on which to use IGMPv3 protocol.
required: False
type: str
pn_enable_vlans:
description:
- enable per VLAN IGMP snooping.
required: False
type: str
pn_vxlan:
description:
- enable or disable IGMP snooping on vxlans.
required: False
type: bool
pn_query_max_response_time:
description:
- maximum response time, in seconds, advertised in IGMP queries.
required: False
type: str
pn_scope:
description:
- IGMP snooping scope - fabric or local.
required: False
choices: ['local', 'fabric']
pn_no_snoop_linklocal_vlans:
description:
- Remove snooping of link-local groups(224.0.0.0/24) on these vlans.
required: False
type: str
pn_snoop_linklocal_vlans:
description:
- Allow snooping of link-local groups(224.0.0.0/24) on these vlans.
required: False
type: str
s�
- name: 'Modify IGMP Snooping'
pn_igmp_snooping:
pn_cliswitch: 'sw01'
state: 'update'
pn_vxlan: True
pn_enable_vlans: '1-399,401-4092'
pn_no_snoop_linklocal_vlans: 'none'
pn_igmpv3_vlans: '1-399,401-4092'
- name: 'Modify IGMP Snooping'
pn_igmp_snooping:
pn_cliswitch: 'sw01'
state: 'update'
pn_vxlan: False
pn_enable_vlans: '1-399'
pn_no_snoop_linklocal_vlans: 'none'
pn_igmpv3_vlans: '1-399'
s�
command:
description: the CLI command run on the target node.
returned: always
type: str
stdout:
description: set of responses from the igmp-snooping command.
returned: always
type: list
stderr:
description: set of error responses from the igmp-snooping command.
returned: on error
type: list
changed:
description: indicates whether the CLI caused changes on the target.
returned: always
type: bool
( t
AnsibleModule( t pn_clit run_clit booleanArgsc C` s& t d d � } t d t d t d t d d � d t d t d d d | j � � d
t d t d d � d t d t d d � d
t d t d d � d t d t d d � d t d t d d � d t d t d d � d t d t d d � d t d t d d d d d g � d t d t d d � d t d t d d � � d d
d d
d d d d d d d g
g � } | j d } | j d } | j d
} | j d } | j d
} | j d } | j d } | j d } | j d }
| j d } | j d } | j d }
| | } t | | � } | d k r| d | 7} | t | d d � 7} | t | d d � 7} | rn| d | 7} n | r�| d | 7} n | r�| d | 7} n | r�| d | 7} n |
r�| d! |
7} n | r�| d"