network/aos - Fix doc for session information (#21718)

* Fix EXAMPLES to make session variable homogeneous across all modules

* Fix parameter name in EXAMPLE, template not design_template
This commit is contained in:
Damien 2017-02-21 06:56:12 -08:00 committed by John R Barker
parent 6e9244a9e1
commit 6fadddeaba
10 changed files with 61 additions and 61 deletions

View file

@ -66,7 +66,7 @@ EXAMPLES = '''
- name: "Create ASN Pool"
aos_asn_pool:
session: "{{ session_ok }}"
session: "{{ aos_session }}"
name: "my-asn-pool"
ranges:
- [ 100, 200 ]
@ -86,32 +86,32 @@ EXAMPLES = '''
- name: "Delete ASN Pool"
aos_asn_pool:
session: "{{ session_ok }}"
session: "{{ aos_session }}"
name: "my-asn-pool"
state: absent
- name: "Load ASN Pool from File(JSON)"
aos_asn_pool:
session: "{{ session_ok }}"
session: "{{ aos_session }}"
content: "{{ lookup('file', 'resources/asn_pool_saved.json') }}"
state: present
- name: "Delete ASN Pool from File(JSON)"
aos_asn_pool:
session: "{{ session_ok }}"
session: "{{ aos_session }}"
content: "{{ lookup('file', 'resources/asn_pool_saved.json') }}"
state: absent
- name: "Load ASN Pool from File(Yaml)"
aos_asn_pool:
session: "{{ session_ok }}"
session: "{{ aos_session }}"
content: "{{ lookup('file', 'resources/asn_pool_saved.yaml') }}"
state: present
register: test
- name: "Delete ASN Pool from File(Yaml)"
aos_asn_pool:
session: "{{ session_ok }}"
session: "{{ aos_session }}"
content: "{{ lookup('file', 'resources/asn_pool_saved.yaml') }}"
state: absent
'''

View file

@ -71,29 +71,29 @@ options:
EXAMPLES = '''
- name: Creating blueprint
aos_blueprint:
session: "{{aos_session}}"
session: "{{ aos_session }}"
name: "my-blueprint"
design_template: "my-template"
template: "my-template"
reference_arch: two_stage_l3clos
state: present
- name: Access a blueprint and get content
aos_blueprint:
session: "{{aos_session}}"
session: "{{ aos_session }}"
name: "{{ blueprint_name }}"
design_template: "{{ blueprint_template }}"
template: "{{ blueprint_template }}"
state: present
register: bp
- name: Delete a blueprint
aos_blueprint:
session: "{{aos_session}}"
session: "{{ aos_session }}"
name: "my-blueprint"
state: absent
- name: Await blueprint build-ready, and obtain contents
aos_blueprint:
session: "{{aos_session}}"
session: "{{ aos_session }}"
name: "{{ blueprint_name }}"
state: build-ready
register: bp

View file

@ -77,7 +77,7 @@ EXAMPLES = '''
- name: Add Logical Device Maps information in a Blueprint
aos_blueprint_param:
session: "{{session_ok}}"
session: "{{ aos_session }}"
blueprint: "my-blueprint-l2"
name: "logical_device_maps"
value:
@ -90,21 +90,21 @@ EXAMPLES = '''
- name: Access Logical Device Maps information from a Blueprint
aos_blueprint_param:
session: "{{session_ok}}"
session: "{{ aos_session }}"
blueprint: "my-blueprint-l2"
name: "logical_device_maps"
state: present
- name: Reset Logical Device Maps information in a Blueprint
aos_blueprint_param:
session: "{{session_ok}}"
session: "{{ aos_session }}"
blueprint: "my-blueprint-l2"
name: "logical_device_maps"
state: absent
- name: Get list of all supported Params for a blueprint
aos_blueprint_param:
session: "{{session_ok}}"
session: "{{ aos_session }}"
blueprint: "my-blueprint-l2"
get_param_list: yes
register: params_list
@ -112,7 +112,7 @@ EXAMPLES = '''
- name: Add Resource Pools information in a Blueprint, by providing a param_map
aos_blueprint_param:
session: "{{session_ok}}"
session: "{{ aos_session }}"
blueprint: "my-blueprint-l2"
name: "resource_pools"
value:

View file

@ -61,21 +61,21 @@ EXAMPLES = '''
- name: "Access Existing Virtual Network"
aos_blueprint_virtnet:
session: "{{ session_ok }}"
session: "{{ aos_session }}"
blueprint: "my-blueprint-l2"
name: "my-virtual-network"
state: present
- name: "Delete Virtual Network with JSON File"
aos_blueprint_virtnet:
session: "{{ session_ok }}"
session: "{{ aos_session }}"
blueprint: "my-blueprint-l2"
content: "{{ lookup('file', 'resources/virtual-network-02.json') }}"
state: absent
- name: "Create Virtual Network"
aos_blueprint_virtnet:
session: "{{ session_ok }}"
session: "{{ aos_session }}"
blueprint: "my-blueprint-l2"
content: "{{ lookup('file', 'resources/virtual-network-02.json') }}"
state: present

View file

@ -69,7 +69,7 @@ EXAMPLES = '''
- name: "Create an External Router"
aos_external_router:
session: "{{ session_ok }}"
session: "{{ aos_session }}"
name: "my-external-router"
loopback: 10.0.0.1
asn: 65000
@ -77,26 +77,26 @@ EXAMPLES = '''
- name: "Check if an External Router exist by ID"
aos_external_router:
session: "{{ session_ok }}"
session: "{{ aos_session }}"
name: "45ab26fc-c2ed-4307-b330-0870488fa13e"
state: present
- name: "Delete an External Router by name"
aos_external_router:
session: "{{ session }}"
session: "{{ aos_session }}"
name: "my-external-router"
state: absent
- name: "Delete an External Router by id"
aos_external_router:
session: "{{ session }}"
session: "{{ aos_session }}"
id: "45ab26fc-c2ed-4307-b330-0870488fa13e"
state: absent
# Save an External Router to a file
- name: "Access External Router 1/3"
aos_external_router:
session: "{{ session_ok }}"
session: "{{ aos_session }}"
name: "my-external-router"
state: present
register: external_router
@ -113,13 +113,13 @@ EXAMPLES = '''
- name: "Load External Router from a JSON file"
aos_external_router:
session: "{{ session_ok }}"
session: "{{ aos_session }}"
content: "{{ lookup('file', 'resources/external_router_saved.json') }}"
state: present
- name: "Load External Router from a YAML file"
aos_external_router:
session: "{{ session_ok }}"
session: "{{ aos_session }}"
content: "{{ lookup('file', 'resources/external_router_saved.yaml') }}"
state: present
'''

View file

@ -66,34 +66,34 @@ EXAMPLES = '''
- name: "Create an IP Pool with one subnet"
aos_ip_pool:
session: "{{ session_ok }}"
session: "{{ aos_session }}"
name: "my-ip-pool"
subnets: [ 172.10.0.0/16 ]
state: present
- name: "Create an IP Pool with multiple subnets"
aos_ip_pool:
session: "{{ session_ok }}"
session: "{{ aos_session }}"
name: "my-other-ip-pool"
subnets: [ 172.10.0.0/16, 192.168.0.0./24 ]
state: present
- name: "Check if an IP Pool exist with same subnets by ID"
aos_ip_pool:
session: "{{ session_ok }}"
session: "{{ aos_session }}"
name: "45ab26fc-c2ed-4307-b330-0870488fa13e"
subnets: [ 172.10.0.0/16, 192.168.0.0./24 ]
state: present
- name: "Delete an IP Pool by name"
aos_ip_pool:
session: "{{ session }}"
session: "{{ aos_session }}"
name: "my-ip-pool"
state: absent
- name: "Delete an IP pool by id"
aos_ip_pool:
session: "{{ session }}"
session: "{{ aos_session }}"
id: "45ab26fc-c2ed-4307-b330-0870488fa13e"
state: absent
@ -101,7 +101,7 @@ EXAMPLES = '''
- name: "Access IP Pool 1/3"
aos_ip_pool:
session: "{{ session_ok }}"
session: "{{ aos_session }}"
name: "my-ip-pool"
subnets: [ 172.10.0.0/16, 172.12.0.0/16 ]
state: present
@ -119,19 +119,19 @@ EXAMPLES = '''
- name: "Load IP Pool from a JSON file"
aos_ip_pool:
session: "{{ session_ok }}"
session: "{{ aos_session }}"
content: "{{ lookup('file', 'resources/ip_pool_saved.json') }}"
state: present
- name: "Load IP Pool from a YAML file"
aos_ip_pool:
session: "{{ session_ok }}"
session: "{{ aos_session }}"
content: "{{ lookup('file', 'resources/ip_pool_saved.yaml') }}"
state: present
- name: "Load IP Pool from a Variable"
aos_ip_pool:
session: "{{ session_ok }}"
session: "{{ aos_session }}"
content:
display_name: my-ip-pool
id: 4276738d-6f86-4034-9656-4bff94a34ea7

View file

@ -64,13 +64,13 @@ EXAMPLES = '''
- name: "Delete a Logical Device by name"
aos_logical_device:
session: "{{ session }}"
session: "{{ aos_session }}"
name: "my-logical-device"
state: absent
- name: "Delete a Logical Device by id"
aos_logical_device:
session: "{{ session }}"
session: "{{ aos_session }}"
id: "45ab26fc-c2ed-4307-b330-0870488fa13e"
state: absent
@ -78,7 +78,7 @@ EXAMPLES = '''
- name: "Access Logical Device 1/3"
aos_logical_device:
session: "{{ session_ok }}"
session: "{{ aos_session }}"
name: "my-logical-device"
state: present
register: logical_device
@ -93,13 +93,13 @@ EXAMPLES = '''
- name: "Load Logical Device from a JSON file"
aos_logical_device:
session: "{{ session_ok }}"
session: "{{ aos_session }}"
content: "{{ lookup('file', 'resources/logical_device_saved.json') }}"
state: present
- name: "Load Logical Device from a YAML file"
aos_logical_device:
session: "{{ session_ok }}"
session: "{{ aos_session }}"
content: "{{ lookup('file', 'resources/logical_device_saved.yaml') }}"
state: present
'''

View file

@ -63,31 +63,31 @@ EXAMPLES = '''
- name: "Create an Logical Device Map with one subnet"
aos_logical_device_map:
session: "{{ session_ok }}"
session: "{{ aos_session }}"
name: "my-logical-device-map"
state: present
- name: "Create an Logical Device Map with multiple subnets"
aos_logical_device_map:
session: "{{ session_ok }}"
session: "{{ aos_session }}"
name: "my-other-logical-device-map"
state: present
- name: "Check if an Logical Device Map exist with same subnets by ID"
aos_logical_device_map:
session: "{{ session_ok }}"
session: "{{ aos_session }}"
name: "45ab26fc-c2ed-4307-b330-0870488fa13e"
state: present
- name: "Delete an Logical Device Map by name"
aos_logical_device_map:
session: "{{ session }}"
session: "{{ aos_session }}"
name: "my-logical-device-map"
state: absent
- name: "Delete an Logical Device Map by id"
aos_logical_device_map:
session: "{{ session }}"
session: "{{ aos_session }}"
id: "45ab26fc-c2ed-4307-b330-0870488fa13e"
state: absent
@ -95,7 +95,7 @@ EXAMPLES = '''
- name: "Access Logical Device Map 1/3"
aos_logical_device_map:
session: "{{ session_ok }}"
session: "{{ aos_session }}"
name: "my-logical-device-map"
state: present
register: logical_device_map
@ -112,13 +112,13 @@ EXAMPLES = '''
- name: "Load Logical Device Map from a JSON file"
aos_logical_device_map:
session: "{{ session_ok }}"
session: "{{ aos_session }}"
content: "{{ lookup('file', 'resources/logical_device_map_saved.json') }}"
state: present
- name: "Load Logical Device Map from a YAML file"
aos_logical_device_map:
session: "{{ session_ok }}"
session: "{{ aos_session }}"
content: "{{ lookup('file', 'resources/logical_device_map_saved.yaml') }}"
state: present

View file

@ -64,13 +64,13 @@ EXAMPLES = '''
- name: "Delete a Rack Type by name"
aos_rack_type:
session: "{{ session }}"
session: "{{ aos_session }}"
name: "my-rack-type"
state: absent
- name: "Delete a Rack Type by id"
aos_rack_type:
session: "{{ session }}"
session: "{{ aos_session }}"
id: "45ab26fc-c2ed-4307-b330-0870488fa13e"
state: absent
@ -78,7 +78,7 @@ EXAMPLES = '''
- name: "Access Rack Type 1/3"
aos_rack_type:
session: "{{ session_ok }}"
session: "{{ aos_session }}"
name: "my-rack-type"
state: present
register: rack_type
@ -93,13 +93,13 @@ EXAMPLES = '''
- name: "Load Rack Type from a JSON file"
aos_rack_type:
session: "{{ session_ok }}"
session: "{{ aos_session }}"
content: "{{ lookup('file', 'resources/rack_type_saved.json') }}"
state: present
- name: "Load Rack Type from a YAML file"
aos_rack_type:
session: "{{ session_ok }}"
session: "{{ aos_session }}"
content: "{{ lookup('file', 'resources/rack_type_saved.yaml') }}"
state: present
'''

View file

@ -63,31 +63,31 @@ EXAMPLES = '''
- name: "Check if an Template exist by name"
aos_template:
session: "{{ session_ok }}"
session: "{{ aos_session }}"
name: "my-template"
state: present
- name: "Check if an Template exist by ID"
aos_template:
session: "{{ session_ok }}"
session: "{{ aos_session }}"
id: "45ab26fc-c2ed-4307-b330-0870488fa13e"
state: present
- name: "Delete an Template by name"
aos_template:
session: "{{ session }}"
session: "{{ aos_session }}"
name: "my-template"
state: absent
- name: "Delete an Template by id"
aos_template:
session: "{{ session }}"
session: "{{ aos_session }}"
id: "45ab26fc-c2ed-4307-b330-0870488fa13e"
state: absent
- name: "Access Template 1/3"
aos_template:
session: "{{ session_ok }}"
session: "{{ aos_session }}"
name: "my-template"
state: present
register: template
@ -102,13 +102,13 @@ EXAMPLES = '''
- name: "Load Template from File (Json)"
aos_template:
session: "{{ session_ok }}"
session: "{{ aos_session }}"
content: "{{ lookup('file', 'resources/template_saved.json') }}"
state: present
- name: "Load Template from File (yaml)"
aos_template:
session: "{{ session_ok }}"
session: "{{ aos_session }}"
content: "{{ lookup('file', 'resources/template_saved.yaml') }}"
state: present
'''