Anons79 Mini Shell

Directory : /lib/python2.7/site-packages/ansible/modules/network/netvisor/
Upload File :
Current File : //lib/python2.7/site-packages/ansible/modules/network/netvisor/pn_vrouter_pim_config.pyc

�
�Udac@`s�ddlmZmZmZeZidd6dgd6dd6ZdZd	Zd
Z	ddl
mZddlm
Z
mZdd
lmZd�Zd�Zedkr�e�ndS(i(tabsolute_importtdivisiontprint_functions1.1tmetadata_versiontpreviewtstatust	communitytsupported_bys�
---
module: pn_vrouter_pim_config
author: "Pluribus Networks (@rajaspachipulusu17)"
version_added: "2.8"
short_description: CLI command to modify vrouter-pim-config
description:
  - This module can be used to modify pim parameters.
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 vrouter-pim-config.
    required: true
    type: str
    choices: ['update']
  pn_query_interval:
    description:
      - igmp query interval in seconds.
    required: false
    type: str
  pn_querier_timeout:
    description:
      - igmp querier timeout in seconds.
    required: false
    type: str
  pn_hello_interval:
    description:
      - hello interval in seconds.
    required: false
    type: str
  pn_vrouter_name:
    description:
      - name of service config.
    required: false
    type: str
s�
- name: pim config modify
  pn_vrouter_pim_config:
    pn_cliswitch: '192.168.1.1'
    pn_query_interval: '10'
    pn_querier_timeout: '30'
    state: 'update'
    pn_vrouter_name: 'ansible-spine1-vrouter'
s�
command:
  description: the CLI command run on the target node.
  returned: always
  type: str
stdout:
  description: set of responses from the vrouter-pim-config command.
  returned: always
  type: list
stderr:
  description: set of error responses from the vrouter-pim-config command.
  returned: on error
  type: list
changed:
  description: indicates whether the CLI caused changes on the target.
  returned: always
  type: bool
(t
AnsibleModule(tpn_clitrun_cli(trun_commandscC`s�|jd}|}|d7}t||�d}|rE|j�}n||krTntS|}|d|7}t||�d}|r�|j�}nd|kr�tStS(s�
    This method checks for pim ssm config using the vrouter-show command.
    If a user already exists on the given switch, return True else False.
    :param module: The Ansible module to fetch input parameters
    :param cli: The CLI string
    tpn_vrouter_names* vrouter-show format name no-show-headers is8 vrouter-show name %s format proto-multi no-show-headerstnone(tparamsRtsplittFalsetTrue(tmoduletclitnametshowtout((sZ/usr/lib/python2.7/site-packages/ansible/modules/network/netvisor/pn_vrouter_pim_config.pyt	check_cliZs

cC`s�tdd�}tdtdtdtdd�dtdtddd	|j��d
tdtdd�dtdtdd�dtdtdd�d
tdtdd��dddd
ggfdd
ddgg�}|jd}|jd}|jd
}|jd}|jd}|jd
}||}t||�}	|dkr�t||	�}
|
tkry|jdtdd�n|	d||f7}	|r�|	d|7}	n|r�|	d|7}	n|r�|	d|7}	q�nt	||	|�dS(s' This section is for arguments parsing tupdatesvrouter-pim-config-modifyt
argument_spectpn_cliswitchtrequiredttypetstrtstatetchoicestpn_query_intervaltpn_querier_timeouttpn_hello_intervalRtrequired_iftrequired_one_oftskippedtmsgs<vrouter proto-multi is not configured/vrouter is not createds %s vrouter-name %s s querier-timeout s hello-interval s query-interval N(
tdictRRRtkeysRR	Rt	exit_jsonR
(t	state_mapRt	cliswitchRtquery_intervaltquerier_timeoutthello_intervaltvrouter_nametcommandRtPIM_SSM_CONFIG((sZ/usr/lib/python2.7/site-packages/ansible/modules/network/netvisor/pn_vrouter_pim_config.pytmainvsJ	






	
t__main__N(t
__future__RRRRt
__metaclass__tANSIBLE_METADATAt
DOCUMENTATIONtEXAMPLEStRETURNtansible.module_utils.basicRt-ansible.module_utils.network.netvisor.pn_nvosR	R
t.ansible.module_utils.network.netvisor.netvisorRRR2t__name__(((sZ/usr/lib/python2.7/site-packages/ansible/modules/network/netvisor/pn_vrouter_pim_config.pyt<module>s


+
		8

Anons79 File Manager Version 1.0, Coded By Anons79
Email: [email protected]