From 319b2b28cb0a92a12d3b2af25b6b4872036fe4aa Mon Sep 17 00:00:00 2001 From: Josh Lothian Date: Mon, 19 Sep 2016 21:22:12 -0500 Subject: [PATCH] Fix YAML syntax in NXOS documentation (#4922) * Fix YAML syntax in NXOS documentation Use ':' and not '=' to ensure valid YAML in the EXAMPLES * Correcting introduced syntax error --- .../modules/network/nxos/nxos_aaa_server.py | 40 +++++++------- .../network/nxos/nxos_aaa_server_host.py | 50 +++++++++--------- lib/ansible/modules/network/nxos/nxos_bgp.py | 7 +-- .../modules/network/nxos/nxos_bgp_af.py | 12 ++--- .../modules/network/nxos/nxos_evpn_global.py | 5 +- .../network/nxos/nxos_igmp_snooping.py | 12 ++--- .../network/nxos/nxos_interface_ospf.py | 6 +-- lib/ansible/modules/network/nxos/nxos_mtu.py | 41 ++++++++------- lib/ansible/modules/network/nxos/nxos_ntp.py | 14 ++--- .../modules/network/nxos/nxos_ntp_auth.py | 14 ++--- .../modules/network/nxos/nxos_ntp_options.py | 14 ++--- lib/ansible/modules/network/nxos/nxos_ospf.py | 2 +- .../network/nxos/nxos_overlay_global.py | 2 +- lib/ansible/modules/network/nxos/nxos_pim.py | 2 +- .../network/nxos/nxos_pim_interface.py | 52 +++++++++---------- .../network/nxos/nxos_snmp_community.py | 12 ++--- .../modules/network/nxos/nxos_snmp_contact.py | 10 ++-- .../modules/network/nxos/nxos_snmp_host.py | 14 ++--- .../network/nxos/nxos_snmp_location.py | 22 ++++---- .../modules/network/nxos/nxos_snmp_traps.py | 24 ++++----- .../modules/network/nxos/nxos_snmp_user.py | 16 +++--- .../modules/network/nxos/nxos_static_route.py | 8 +-- lib/ansible/modules/network/nxos/nxos_udld.py | 22 ++++---- .../network/nxos/nxos_udld_interface.py | 36 ++++++------- lib/ansible/modules/network/nxos/nxos_vpc.py | 14 ++--- .../network/nxos/nxos_vpc_interface.py | 4 +- .../modules/network/nxos/nxos_vrf_af.py | 6 +-- .../modules/network/nxos/nxos_vtp_domain.py | 10 ++-- .../modules/network/nxos/nxos_vtp_password.py | 22 ++++---- .../modules/network/nxos/nxos_vtp_version.py | 10 ++-- .../modules/network/nxos/nxos_vxlan_vtep.py | 12 ++--- .../network/nxos/nxos_vxlan_vtep_vni.py | 6 +-- 32 files changed, 263 insertions(+), 258 deletions(-) diff --git a/lib/ansible/modules/network/nxos/nxos_aaa_server.py b/lib/ansible/modules/network/nxos/nxos_aaa_server.py index 147a9137a71..43cc3425f26 100644 --- a/lib/ansible/modules/network/nxos/nxos_aaa_server.py +++ b/lib/ansible/modules/network/nxos/nxos_aaa_server.py @@ -86,33 +86,33 @@ EXAMPLES = ''' # Radius Server Basic settings - name: "Radius Server Basic settings" nxos_aaa_server: - server_type=radius - server_timeout=9 - deadtime=20 - directed_request=enabled - host={{ inventory_hostname }} - username={{ un }} - password={{ pwd }} + server_type: radius + server_timeout: 9 + deadtime: 20 + directed_request: enabled + host: inventory_hostname }} + username: un }} + password: pwd }} # Tacacs Server Basic settings - name: "Tacacs Server Basic settings" nxos_aaa_server: - server_type=tacacs - server_timeout=8 - deadtime=19 - directed_request=disabled - host={{ inventory_hostname }} - username={{ un }} - password={{ pwd }} + server_type: tacacs + server_timeout: 8 + deadtime: 19 + directed_request: disabled + host: inventory_hostname }} + username: un }} + password: pwd }} # Setting Global Key - name: "AAA Server Global Key" nxos_aaa_server: - server_type=radius - global_key=test_key - host={{ inventory_hostname }} - username={{ un }} - password={{ pwd }} + server_type: radius + global_key: test_key + host: inventory_hostname }} + username: un }} + password: pwd }} ''' RETURN = ''' @@ -564,4 +564,4 @@ def main(): if __name__ == '__main__': - main() \ No newline at end of file + main() diff --git a/lib/ansible/modules/network/nxos/nxos_aaa_server_host.py b/lib/ansible/modules/network/nxos/nxos_aaa_server_host.py index ed11ddd1f5f..28f24f86adf 100644 --- a/lib/ansible/modules/network/nxos/nxos_aaa_server_host.py +++ b/lib/ansible/modules/network/nxos/nxos_aaa_server_host.py @@ -83,38 +83,38 @@ EXAMPLES = ''' # Radius Server Host Basic settings - name: "Radius Server Host Basic settings" nxos_aaa_server_host: - state=present - server_type=radius - address=1.2.3.4 - acct_port=2084 - host_timeout=10 - host={{ inventory_hostname }} - username={{ un }} - password={{ pwd }} + state: present + server_type: radius + address: 1.2.3.4 + acct_port: 2084 + host_timeout: 10 + host: {{ inventory_hostname }} + username: {{ un }} + password: {{ pwd }} # Radius Server Host Key Configuration - name: "Radius Server Host Key Configuration" nxos_aaa_server_host: - state=present - server_type=radius - address=1.2.3.4 - key=hello - encrypt_type=7 - host={{ inventory_hostname }} - username={{ un }} - password={{ pwd }} + state: present + server_type: radius + address: 1.2.3.4 + key: hello + encrypt_type: 7 + host: inventory_hostname }} + username: {{ un }} + password: {{ pwd }} # TACACS Server Host Configuration - name: "Tacacs Server Host Configuration" nxos_aaa_server_host: - state=present - server_type=tacacs - tacacs_port=89 - host_timeout=10 - address=5.6.7.8 - host={{ inventory_hostname }} - username={{ un }} - password={{ pwd }} + state: present + server_type: tacacs + tacacs_port: 89 + host_timeout: 10 + address: 5.6.7.8 + host: inventory_hostname }} + username: un }} + password: pwd }} ''' RETURN = ''' @@ -575,4 +575,4 @@ def main(): if __name__ == '__main__': - main() \ No newline at end of file + main() diff --git a/lib/ansible/modules/network/nxos/nxos_bgp.py b/lib/ansible/modules/network/nxos/nxos_bgp.py index 48900f4544c..5ba394bda47 100644 --- a/lib/ansible/modules/network/nxos/nxos_bgp.py +++ b/lib/ansible/modules/network/nxos/nxos_bgp.py @@ -278,9 +278,10 @@ options: EXAMPLES = ''' # configure a simple asn - nxos_bgp: - asn=65535 - vrf=default - state=present + asn: 65535 + vrf: test + router_id: 1.1.1.1 + state: present username: "{{ un }}" password: "{{ pwd }}" host: "{{ inventory_hostname }}" diff --git a/lib/ansible/modules/network/nxos/nxos_bgp_af.py b/lib/ansible/modules/network/nxos/nxos_bgp_af.py index 1bec4119b8c..8add9dfb4ad 100644 --- a/lib/ansible/modules/network/nxos/nxos_bgp_af.py +++ b/lib/ansible/modules/network/nxos/nxos_bgp_af.py @@ -247,12 +247,12 @@ options: EXAMPLES = ''' # configure a simple address-family - nxos_bgp_af: - asn=65535 - vrf=TESTING - afi=ipv4 - safi=unicast - advertise_l2vpn_evpn=true - state=present + asn: 65535 + vrf: TESTING + afi: ipv4 + safi: unicast + advertise_l2vpn_evpn: true + state: present ''' RETURN = ''' diff --git a/lib/ansible/modules/network/nxos/nxos_evpn_global.py b/lib/ansible/modules/network/nxos/nxos_evpn_global.py index c7f2976be64..e0df54e7f95 100644 --- a/lib/ansible/modules/network/nxos/nxos_evpn_global.py +++ b/lib/ansible/modules/network/nxos/nxos_evpn_global.py @@ -40,7 +40,10 @@ options: ''' EXAMPLES = ''' - nxos_evpn_global: - nv_overlay_evpn=true + nv_overlay_evpn: true + username: "{{ un }}" + password: "{{ pwd }}" + host: "{{ inventory_hostname }}" ''' RETURN = ''' diff --git a/lib/ansible/modules/network/nxos/nxos_igmp_snooping.py b/lib/ansible/modules/network/nxos/nxos_igmp_snooping.py index f8c6c4af7d8..1e11a9246d5 100644 --- a/lib/ansible/modules/network/nxos/nxos_igmp_snooping.py +++ b/lib/ansible/modules/network/nxos/nxos_igmp_snooping.py @@ -72,10 +72,10 @@ options: EXAMPLES = ''' # ensure igmp snooping params supported in this module are in there default state - nxos_igmp_snooping: - state=default - host={{ inventory_hostname }} - username={{ un }} - password={{ pwd }} + state: default + host: inventory_hostname }} + username: un }} + password: pwd }} # ensure following igmp snooping params are in the desired state - nxos_igmp_snooping: @@ -86,8 +86,8 @@ EXAMPLES = ''' report_supp: true v3_report_supp: true host: "{{ inventory_hostname }}" - username={{ un }} - password={{ pwd }} + username: {{ un }} + password: {{ pwd }} ''' RETURN = ''' diff --git a/lib/ansible/modules/network/nxos/nxos_interface_ospf.py b/lib/ansible/modules/network/nxos/nxos_interface_ospf.py index fc424e2805f..f16e6d33c41 100644 --- a/lib/ansible/modules/network/nxos/nxos_interface_ospf.py +++ b/lib/ansible/modules/network/nxos/nxos_interface_ospf.py @@ -120,9 +120,9 @@ options: ''' EXAMPLES = ''' - nxos_interface_ospf: - interface=ethernet1/32 - ospf=1 - area=1 + interface: ethernet1/32 + ospf: 1 + area: 1 cost=default username: "{{ un }}" password: "{{ pwd }}" diff --git a/lib/ansible/modules/network/nxos/nxos_mtu.py b/lib/ansible/modules/network/nxos/nxos_mtu.py index 379eca9cdb5..e8cd0f205ca 100644 --- a/lib/ansible/modules/network/nxos/nxos_mtu.py +++ b/lib/ansible/modules/network/nxos/nxos_mtu.py @@ -56,34 +56,35 @@ options: EXAMPLES = ''' # Ensure system mtu is 9126 - nxos_mtu: - sysmtu=9216 - host={{ inventory_hostname }} - username={{ un }} - password={{ pwd }} + sysmtu: 9216 + host: {{ inventory_hostname }} + username: {{ un }} + password: {{ pwd }} # Config mtu on Eth1/1 (routed interface) - nxos_mtu: - interface=Ethernet1/1 - mtu=1600 - host={{ inventory_hostname }} - username={{ un }} - password={{ pwd }} + interface: Ethernet1/1 + mtu: 1600 + host: {{ inventory_hostname }} + username: {{ un }} + password: {{ pwd }} # Config mtu on Eth1/3 (switched interface) - nxos_mtu: - interface=Ethernet1/3 - mtu=9216 - host={{ inventory_hostname }} - username={{ un }} - password={{ pwd }} + interface: Ethernet1/3 + mtu: 9216 + host: {{ inventory_hostname }} + username: {{ un }} + password: {{ pwd }} # Unconfigure mtu on a given interface - nxos_mtu: - interface=Ethernet1/3 - mtu=9216 host={{ inventory_hostname }} - username={{ un }} - password={{ pwd }} - state=absent + interface: Ethernet1/3 + mtu: 9216 + host: {{ inventory_hostname }} + username: {{ un }} + password: {{ pwd }} + state: absent ''' RETURN = ''' @@ -591,4 +592,4 @@ def main(): if __name__ == '__main__': - main() \ No newline at end of file + main() diff --git a/lib/ansible/modules/network/nxos/nxos_ntp.py b/lib/ansible/modules/network/nxos/nxos_ntp.py index 7e64fccdb50..81de38bef84 100644 --- a/lib/ansible/modules/network/nxos/nxos_ntp.py +++ b/lib/ansible/modules/network/nxos/nxos_ntp.py @@ -78,12 +78,12 @@ options: EXAMPLES = ''' # Set NTP Server with parameters - nxos_ntp: - server=1.2.3.4 - key_id=32 - prefer=enabled - host={{ inventory_hostname }} - username={{ un }} - password={{ pwd }} + server: 1.2.3.4 + key_id: 32 + prefer: enabled + host: {{ inventory_hostname }} + username: {{ un }} + password: {{ pwd }} ''' RETURN = ''' @@ -629,4 +629,4 @@ def main(): from ansible.module_utils.basic import * if __name__ == '__main__': - main() \ No newline at end of file + main() diff --git a/lib/ansible/modules/network/nxos/nxos_ntp_auth.py b/lib/ansible/modules/network/nxos/nxos_ntp_auth.py index fc2d1c52a3f..28da3a74468 100644 --- a/lib/ansible/modules/network/nxos/nxos_ntp_auth.py +++ b/lib/ansible/modules/network/nxos/nxos_ntp_auth.py @@ -74,12 +74,12 @@ options: EXAMPLES = ''' # Basic NTP authentication configuration - nxos_ntp_auth: - key_id=32 - md5string=hello - auth_type=text - host={{ inventory_hostname }} - username={{ un }} - password={{ pwd }} + key_id: 32 + md5string: hello + auth_type: text + host: {{ inventory_hostname }} + username: {{ un }} + password: {{ pwd }} ''' RETURN = ''' @@ -566,4 +566,4 @@ def main(): module.exit_json(**results) if __name__ == '__main__': - main() \ No newline at end of file + main() diff --git a/lib/ansible/modules/network/nxos/nxos_ntp_options.py b/lib/ansible/modules/network/nxos/nxos_ntp_options.py index 7615a0401aa..a3599df3563 100644 --- a/lib/ansible/modules/network/nxos/nxos_ntp_options.py +++ b/lib/ansible/modules/network/nxos/nxos_ntp_options.py @@ -62,12 +62,12 @@ options: EXAMPLES = ''' # Basic NTP options configuration - nxos_ntp_options: - master=true - stratum=12 - logging=false - host={{ inventory_hostname }} - username={{ un }} - password={{ pwd }} + master: true + stratum: 12 + logging: false + host: {{ inventory_hostname }} + username: {{ un }} + password: {{ pwd }} ''' RETURN = ''' @@ -512,4 +512,4 @@ def main(): if __name__ == '__main__': - main() \ No newline at end of file + main() diff --git a/lib/ansible/modules/network/nxos/nxos_ospf.py b/lib/ansible/modules/network/nxos/nxos_ospf.py index 18a47b3f498..b2efd4577d2 100644 --- a/lib/ansible/modules/network/nxos/nxos_ospf.py +++ b/lib/ansible/modules/network/nxos/nxos_ospf.py @@ -46,7 +46,7 @@ options: EXAMPLES = ''' - nxos_ospf: - ospf=ntc + ospf: 1 state: present username: "{{ un }}" password: "{{ pwd }}" diff --git a/lib/ansible/modules/network/nxos/nxos_overlay_global.py b/lib/ansible/modules/network/nxos/nxos_overlay_global.py index 6e4f1317547..dae8fe04aae 100644 --- a/lib/ansible/modules/network/nxos/nxos_overlay_global.py +++ b/lib/ansible/modules/network/nxos/nxos_overlay_global.py @@ -44,7 +44,7 @@ options: ''' EXAMPLES = ''' - nxos_overlay_global: - anycast_gateway_mac="b.b.b" + anycast_gateway_mac: "b.b.b" username: "{{ un }}" password: "{{ pwd }}" host: "{{ inventory_hostname }}" diff --git a/lib/ansible/modules/network/nxos/nxos_pim.py b/lib/ansible/modules/network/nxos/nxos_pim.py index 063d6b5bffe..3fc273d07ac 100644 --- a/lib/ansible/modules/network/nxos/nxos_pim.py +++ b/lib/ansible/modules/network/nxos/nxos_pim.py @@ -40,7 +40,7 @@ options: ''' EXAMPLES = ''' - nxos_pim: - ssm_range="232.0.0.0/8" + ssm_range: "232.0.0.0/8" username: "{{ un }}" password: "{{ pwd }}" host: "{{ inventory_hostname }}" diff --git a/lib/ansible/modules/network/nxos/nxos_pim_interface.py b/lib/ansible/modules/network/nxos/nxos_pim_interface.py index 00ace4b9fb8..68f0cbb775c 100644 --- a/lib/ansible/modules/network/nxos/nxos_pim_interface.py +++ b/lib/ansible/modules/network/nxos/nxos_pim_interface.py @@ -108,40 +108,40 @@ options: EXAMPLES = ''' # ensure PIM is not running on the interface - nxos_pim_interface: - interface=eth1/33 - state=absent - host={{ inventory_hostname }} - username={{ un }} - password={{ pwd }} + interface: eth1/33 + state: absent + host: {{ inventory_hostname }} + username: {{ un }} + password: {{ pwd }} # ensure the interface has pim-sm enabled with the appropriate priority and hello interval - nxos_pim_interface: - interface=eth1/33 - dr_prio=10 - hello_interval=40 - state=present - host={{ inventory_hostname }} - username={{ un }} - password={{ pwd }} + interface: eth1/33 + dr_prio: 10 + hello_interval: 40 + state: present + host: {{ inventory_hostname }} + username: {{ un }} + password: {{ pwd }} # ensure join-prune policies exist - nxos_pim_interface: - interface=eth1/33 - jp_policy_in=JPIN - jp_policy_out=JPOUT - jp_type_in=routemap - jp_type_out=routemap - host={{ inventory_hostname }} - username={{ un }} - password={{ pwd }} + interface: eth1/33 + jp_policy_in: JPIN + jp_policy_out: JPOUT + jp_type_in: routemap + jp_type_out: routemap + host: {{ inventory_hostname }} + username: {{ un }} + password: {{ pwd }} # ensure defaults are in place - nxos_pim_interface: - interface=eth1/33 - state=default - host={{ inventory_hostname }} - username={{ un }} - password={{ pwd }} + interface: eth1/33 + state: default + host: {{ inventory_hostname }} + username: {{ un }} + password: {{ pwd }} ''' RETURN = ''' @@ -926,4 +926,4 @@ def main(): if __name__ == '__main__': - main() \ No newline at end of file + main() diff --git a/lib/ansible/modules/network/nxos/nxos_snmp_community.py b/lib/ansible/modules/network/nxos/nxos_snmp_community.py index 9e3aa1de2ec..137dd7715b0 100644 --- a/lib/ansible/modules/network/nxos/nxos_snmp_community.py +++ b/lib/ansible/modules/network/nxos/nxos_snmp_community.py @@ -59,12 +59,12 @@ options: EXAMPLES = ''' # ensure snmp community is configured - nxos_snmp_community: - community=TESTING7 - group=network-operator - state=present - host={{ inventory_hostname }} - username={{ un }} - password={{ pwd }} + community: TESTING7 + group: network-operator + state: present + host: {{ inventory_hostname }} + username: {{ un }} + password: {{ pwd }} ''' RETURN = ''' diff --git a/lib/ansible/modules/network/nxos/nxos_snmp_contact.py b/lib/ansible/modules/network/nxos/nxos_snmp_contact.py index a1adb1a6793..e6982a8a4d4 100644 --- a/lib/ansible/modules/network/nxos/nxos_snmp_contact.py +++ b/lib/ansible/modules/network/nxos/nxos_snmp_contact.py @@ -45,11 +45,11 @@ options: EXAMPLES = ''' # ensure snmp contact is configured - nxos_snmp_contact: - contact=Test - state=present - host={{ inventory_hostname }} - username={{ un }} - password={{ pwd }} + contact: Test + state: present + host: {{ inventory_hostname }} + username: {{ un }} + password: {{ pwd }} ''' RETURN = ''' diff --git a/lib/ansible/modules/network/nxos/nxos_snmp_host.py b/lib/ansible/modules/network/nxos/nxos_snmp_host.py index a3bef8ffd32..d3b431de8ce 100644 --- a/lib/ansible/modules/network/nxos/nxos_snmp_host.py +++ b/lib/ansible/modules/network/nxos/nxos_snmp_host.py @@ -79,12 +79,12 @@ options: EXAMPLES = ''' # ensure snmp host is configured - nxos_snmp_host: - snmp_host=3.3.3.3 - community=TESTING - state=present - host={{ inventory_hostname }} - username={{ un }} - password={{ pwd }} + snmp_host: 3.3.3.3 + community: TESTING + state: present + host: {{ inventory_hostname }} + username: {{ un }} + password: {{ pwd }} ''' RETURN = ''' @@ -631,4 +631,4 @@ def main(): if __name__ == "__main__": - main() \ No newline at end of file + main() diff --git a/lib/ansible/modules/network/nxos/nxos_snmp_location.py b/lib/ansible/modules/network/nxos/nxos_snmp_location.py index 45b7168bda6..ea5ef58f07d 100644 --- a/lib/ansible/modules/network/nxos/nxos_snmp_location.py +++ b/lib/ansible/modules/network/nxos/nxos_snmp_location.py @@ -42,19 +42,19 @@ options: EXAMPLES = ''' # ensure snmp location is configured - nxos_snmp_location: - location=Test - state=present - host={{ inventory_hostname }} - username={{ un }} - password={{ pwd }} + location: Test + state: present + host: {{ inventory_hostname }} + username: {{ un }} + password: {{ pwd }} # ensure snmp location is not configured - nxos_snmp_location: - location=Test - state=absent - host={{ inventory_hostname }} - username={{ un }} - password={{ pwd }} + location: Test + state: absent + host: {{ inventory_hostname }} + username: {{ un }} + password: {{ pwd }} ''' RETURN = ''' @@ -414,4 +414,4 @@ def main(): from ansible.module_utils.basic import * if __name__ == "__main__": - main() \ No newline at end of file + main() diff --git a/lib/ansible/modules/network/nxos/nxos_snmp_traps.py b/lib/ansible/modules/network/nxos/nxos_snmp_traps.py index 98c779fe3eb..c48eafa0eba 100644 --- a/lib/ansible/modules/network/nxos/nxos_snmp_traps.py +++ b/lib/ansible/modules/network/nxos/nxos_snmp_traps.py @@ -49,22 +49,22 @@ options: choices: ['enabled','disabled'] ''' -EXAMPLES = ''' +EXAMPLES = ''' # ensure lldp trap configured - nxos_snmp_traps: - group=lldp - state=enabled - host={{ inventory_hostname }} - username={{ un }} - password={{ pwd }} + group: lldp + state: enabled + host: {{ inventory_hostname }} + username: {{ un }} + password: {{ pwd }} # ensure lldp trap is not configured - nxos_snmp_traps: - group=lldp - state=disabled - host={{ inventory_hostname }} - username={{ un }} - password={{ pwd }} + group: lldp + state: disabled + host: {{ inventory_hostname }} + username: {{ un }} + password: {{ pwd }} ''' RETURN = ''' @@ -493,4 +493,4 @@ def main(): if __name__ == '__main__': - main() \ No newline at end of file + main() diff --git a/lib/ansible/modules/network/nxos/nxos_snmp_user.py b/lib/ansible/modules/network/nxos/nxos_snmp_user.py index 5e9eec29a48..9e1c051739d 100644 --- a/lib/ansible/modules/network/nxos/nxos_snmp_user.py +++ b/lib/ansible/modules/network/nxos/nxos_snmp_user.py @@ -69,13 +69,13 @@ options: EXAMPLES = ''' - nxos_snmp_user: - user=ntc - group=network-operator - auth=md5 - pwd=test_password - host={{ inventory_hostname }} - username={{ un }} - password={{ pwd }} + user: ntc + group: network-operator + auth: md5 + pwd: test_password + host: {{ inventory_hostname }} + username: {{ un }} + password: {{ pwd }} ''' RETURN = ''' @@ -555,4 +555,4 @@ def main(): if __name__ == "__main__": - main() \ No newline at end of file + main() diff --git a/lib/ansible/modules/network/nxos/nxos_static_route.py b/lib/ansible/modules/network/nxos/nxos_static_route.py index bf943043e3f..ccb837bb798 100644 --- a/lib/ansible/modules/network/nxos/nxos_static_route.py +++ b/lib/ansible/modules/network/nxos/nxos_static_route.py @@ -72,10 +72,10 @@ options: EXAMPLES = ''' - nxos_static_route: - prefix="192.168.20.64/24" - next_hop="3.3.3.3" - route_name=testing - pref=100 + prefix: "192.168.20.64/24" + next_hop: "3.3.3.3" + route_name: testing + pref: 100 username: "{{ un }}" password: "{{ pwd }}" host: "{{ inventory_hostname }}" diff --git a/lib/ansible/modules/network/nxos/nxos_udld.py b/lib/ansible/modules/network/nxos/nxos_udld.py index 04f8373e234..cd377870ee3 100644 --- a/lib/ansible/modules/network/nxos/nxos_udld.py +++ b/lib/ansible/modules/network/nxos/nxos_udld.py @@ -60,19 +60,19 @@ options: EXAMPLES = ''' # ensure udld aggressive mode is globally disabled and se global message interval is 20 - nxos_udld: - aggressive=disabled - msg_time=20 - host={{ inventory_hostname }} - username={{ un }} - password={{ pwd }} + aggressive: disabled + msg_time: 20 + host: {{ inventory_hostname }} + username: {{ un }} + password: {{ pwd }} # Ensure agg mode is globally enabled and msg time is 15 - nxos_udld: - aggressive=enabled - msg_time=15 - host={{ inventory_hostname }} - username={{ un }} - password={{ pwd }} + aggressive: enabled + msg_time: 15 + host: {{ inventory_hostname }} + username: {{ un }} + password: {{ pwd }} ''' RETURN = ''' @@ -499,4 +499,4 @@ def main(): if __name__ == '__main__': - main() \ No newline at end of file + main() diff --git a/lib/ansible/modules/network/nxos/nxos_udld_interface.py b/lib/ansible/modules/network/nxos/nxos_udld_interface.py index 28c3a3ece7a..593aaa3fcd7 100644 --- a/lib/ansible/modules/network/nxos/nxos_udld_interface.py +++ b/lib/ansible/modules/network/nxos/nxos_udld_interface.py @@ -48,29 +48,29 @@ options: EXAMPLES = ''' # ensure Ethernet1/1 is configured to be in aggressive mode - nxos_udld_interface: - interface=Ethernet1/1 - mode=aggressive - state=present - host={{ inventory_hostname }} - username={{ un }} - password={{ pwd }} + interface: Ethernet1/1 + mode: aggressive + state: present + host: {{ inventory_hostname }} + username: {{ un }} + password: {{ pwd }} # Remove the aggressive config only if it's currently in aggressive mode and then disable udld (switch default) - nxos_udld_interface: - interface=Ethernet1/1 - mode=aggressive - state=absent - host={{ inventory_hostname }} - username={{ un }} - password={{ pwd }} + interface: Ethernet1/1 + mode: aggressive + state: absent + host: {{ inventory_hostname }} + username: {{ un }} + password: {{ pwd }} # ensure Ethernet1/1 has aggressive mode enabled - nxos_udld_interface: - interface=Ethernet1/1 - mode=enabled - host={{ inventory_hostname }} - username={{ un }} - password={{ pwd }} + interface: Ethernet1/1 + mode: enabled + host: {{ inventory_hostname }} + username: {{ un }} + password: {{ pwd }} ''' RETURN = ''' @@ -511,4 +511,4 @@ def main(): module.exit_json(**results) if __name__ == '__main__': - main() \ No newline at end of file + main() diff --git a/lib/ansible/modules/network/nxos/nxos_vpc.py b/lib/ansible/modules/network/nxos/nxos_vpc.py index 8ad69e2b899..37893f164f4 100644 --- a/lib/ansible/modules/network/nxos/nxos_vpc.py +++ b/lib/ansible/modules/network/nxos/nxos_vpc.py @@ -90,13 +90,13 @@ options: EXAMPLES = ''' # configure a simple asn - nxos_vpc: - domain=100 - role_priority=1000 - system_priority=2000 - pkl_dest=192.168.100.4 - pkl_src=10.1.100.20 - peer_gw=true - auto_recovery=true + domain: 100 + role_priority: 1000 + system_priority: 2000 + pkl_dest: 192.168.100.4 + pkl_src: 10.1.100.20 + peer_gw: true + auto_recovery: true username: "{{ un }}" password: "{{ pwd }}" host: "{{ inventory_hostname }}" diff --git a/lib/ansible/modules/network/nxos/nxos_vpc_interface.py b/lib/ansible/modules/network/nxos/nxos_vpc_interface.py index 9cae7403437..0069d0a8d6b 100644 --- a/lib/ansible/modules/network/nxos/nxos_vpc_interface.py +++ b/lib/ansible/modules/network/nxos/nxos_vpc_interface.py @@ -58,8 +58,8 @@ options: EXAMPLES = ''' - nxos_vpc_portchannel: - portchannel=10 - vpc=100 + portchannel: 10 + vpc: 100 username: "{{ un }}" password: "{{ pwd }}" host: "{{ inventory_hostname }}" diff --git a/lib/ansible/modules/network/nxos/nxos_vrf_af.py b/lib/ansible/modules/network/nxos/nxos_vrf_af.py index 67e3c3dc39f..45983cffcc9 100644 --- a/lib/ansible/modules/network/nxos/nxos_vrf_af.py +++ b/lib/ansible/modules/network/nxos/nxos_vrf_af.py @@ -67,9 +67,9 @@ options: ''' EXAMPLES = ''' - nxos_vrf_af: - interface=nve1 - vni=6000 - ingress_replication=true + interface: nve1 + vni: 6000 + ingress_replication: true username: "{{ un }}" password: "{{ pwd }}" host: "{{ inventory_hostname }}" diff --git a/lib/ansible/modules/network/nxos/nxos_vtp_domain.py b/lib/ansible/modules/network/nxos/nxos_vtp_domain.py index 68fc8e20a22..7ea1b8c8cde 100644 --- a/lib/ansible/modules/network/nxos/nxos_vtp_domain.py +++ b/lib/ansible/modules/network/nxos/nxos_vtp_domain.py @@ -44,10 +44,10 @@ options: EXAMPLES = ''' # ENSURE VTP DOMAIN IS CONFIGURED - nxos_vtp_domain: - domain=ntc - host={{ inventory_hostname }} - username={{ un }} - password={{ pwd }} + domain: ntc + host: {{ inventory_hostname }} + username: {{ un }} + password: {{ pwd }} ''' @@ -417,4 +417,4 @@ def main(): if __name__ == '__main__': - main() \ No newline at end of file + main() diff --git a/lib/ansible/modules/network/nxos/nxos_vtp_password.py b/lib/ansible/modules/network/nxos/nxos_vtp_password.py index f53ff2ef6a6..9dba96fbb70 100644 --- a/lib/ansible/modules/network/nxos/nxos_vtp_password.py +++ b/lib/ansible/modules/network/nxos/nxos_vtp_password.py @@ -54,19 +54,19 @@ options: EXAMPLES = ''' # ENSURE VTP PASSWORD IS SET - nxos_vtp_password: - password=ntc - state=present - host={{ inventory_hostname }} - username={{ un }} - password={{ pwd }} + password: ntc + state: present + host: {{ inventory_hostname }} + username: {{ un }} + password: {{ pwd }} # ENSURE VTP PASSWORD IS REMOVED - nxos_vtp_password: - password=ntc - state=absent - host={{ inventory_hostname }} - username={{ un }} - password={{ pwd }} + password: ntc + state: absent + host: {{ inventory_hostname }} + username: {{ un }} + password: {{ pwd }} ''' RETURN = ''' @@ -474,4 +474,4 @@ def main(): if __name__ == '__main__': - main() \ No newline at end of file + main() diff --git a/lib/ansible/modules/network/nxos/nxos_vtp_version.py b/lib/ansible/modules/network/nxos/nxos_vtp_version.py index 4979d60a1fe..0d24e9c37c0 100644 --- a/lib/ansible/modules/network/nxos/nxos_vtp_version.py +++ b/lib/ansible/modules/network/nxos/nxos_vtp_version.py @@ -42,10 +42,10 @@ options: EXAMPLES = ''' # ENSURE VTP VERSION IS 2 - nxos_vtp_version: - version=2 - host={{ inventory_hostname }} - username={{ un }} - password={{ pwd }} + version: 2 + host: {{ inventory_hostname }} + username: {{ un }} + password: {{ pwd }} ''' RETURN = ''' @@ -412,4 +412,4 @@ def main(): if __name__ == '__main__': - main() \ No newline at end of file + main() diff --git a/lib/ansible/modules/network/nxos/nxos_vxlan_vtep.py b/lib/ansible/modules/network/nxos/nxos_vxlan_vtep.py index 6581370bf93..00b9639d7d1 100644 --- a/lib/ansible/modules/network/nxos/nxos_vxlan_vtep.py +++ b/lib/ansible/modules/network/nxos/nxos_vxlan_vtep.py @@ -74,12 +74,12 @@ options: ''' EXAMPLES = ''' - nxos_vxlan_vtep: - interface=nve1 - description=default - host_reachability=default - source_interface=Loopback0 - source_interface_hold_down_time=30 - shutdown=default + interface: nve1 + description: default + host_reachability: default + source_interface: Loopback0 + source_interface_hold_down_time: 30 + shutdown: default username: "{{ un }}" password: "{{ pwd }}" host: "{{ inventory_hostname }}" diff --git a/lib/ansible/modules/network/nxos/nxos_vxlan_vtep_vni.py b/lib/ansible/modules/network/nxos/nxos_vxlan_vtep_vni.py index e3b552cacbe..b8e67223912 100644 --- a/lib/ansible/modules/network/nxos/nxos_vxlan_vtep_vni.py +++ b/lib/ansible/modules/network/nxos/nxos_vxlan_vtep_vni.py @@ -80,9 +80,9 @@ options: ''' EXAMPLES = ''' - nxos_vxlan_vtep_vni: - interface=nve1 - vni=6000 - ingress_replication=default + interface: nve1 + vni: 6000 + ingress_replication: default username: "{{ un }}" password: "{{ pwd }}" host: "{{ inventory_hostname }}"