General EOS documentation improvements

Typos, formatting, choices.
pull/18777/head
John Barker 8 years ago committed by Matt Clay
parent e9bf046c26
commit 2b82389705

@ -21,10 +21,10 @@ DOCUMENTATION = """
module: eos_command
version_added: "2.1"
author: "Peter Sprygada (@privateip)"
short_description: Run arbitrary command on EOS device
short_description: Run arbitrary commands on EOS device
description:
- Sends an aribtrary set of commands to an EOS node and returns the results
read from the device. The M(eos_command) module includes an
- Sends an arbitrary set of commands to an EOS node and returns the results
read from the device. This module includes an
argument that will cause the module to wait for a specific condition
before returning or timing out if the condition is not met.
extends_documentation_fragment: eos
@ -33,9 +33,9 @@ options:
description:
- The commands to send to the remote EOS device over the
configured provider. The resulting output from the command
is returned. If the I(waitfor) argument is provided, the
is returned. If the I(wait_for) argument is provided, the
module is not returned until the condition is satisfied or
the number of retries has been exceeded.
the number of I(retries) has been exceeded.
required: true
wait_for:
description:
@ -52,8 +52,8 @@ options:
description:
- Specifies the number of retries a command should be tried
before it is considered failed. The command is run on the
target device every retry and evaluated against the waitfor
conditionals
target device every retry and evaluated against the I(wait_for)
conditionals.
required: false
default: 10
interval:

@ -22,10 +22,10 @@ version_added: "2.1"
author: "Peter Sprygada (@privateip)"
short_description: Manage Arista EOS configuration sections
description:
- Arista EOS configurations use a simple block indent file sytanx
for segementing configuration into sections. This module provides
- Arista EOS configurations use a simple block indent file syntax
for segmenting configuration into sections. This module provides
an implementation for working with eos configuration sections in
a deterministic way. This module works with either CLI or eapi
a deterministic way. This module works with either CLI or eAPI
transports.
extends_documentation_fragment: eos
options:
@ -51,7 +51,7 @@ options:
a change needs to be made. This allows the playbook designer
the opportunity to perform configuration commands prior to pushing
any changes without affecting how the set of commands are matched
against the system
against the system.
required: false
default: null
after:
@ -80,7 +80,7 @@ options:
the modified lines are pushed to the device in configuration
mode. If the replace argument is set to I(block) then the entire
command block is pushed to the device in configuration mode if any
line is not correct
line is not correct.
required: false
default: line
choices: ['line', 'block']
@ -100,8 +100,8 @@ options:
against the contents of source. There are times when it is not
desirable to have the task get the current running-config for
every task in a playbook. The I(config) argument allows the
implementer to pass in the configuruation to use as the base
config for comparision.
implementer to pass in the configuration to use as the base
config for comparison.
required: false
default: null
"""

@ -22,11 +22,13 @@ DOCUMENTATION = """
module: eos_eapi
version_added: "2.1"
author: "Chris Houseknecht (@chouseknecht)"
short_description: Manage and configure EAPI. Requires EOS v4.12 or greater.
short_description: Manage and configure eAPI.
requirements:
- "EOS v4.12 or greater"
description:
- Use to enable or disable EAPI access, and set the port and state
of http, https, localHttp and unix-socket servers.
- When enabling EAPI access the default is to enable HTTP on port
- Use to enable or disable eAPI access, and set the port and state
of http, https, local_http and unix-socket servers.
- When enabling eAPI access the default is to enable HTTP on port
80, enable HTTPS on port 443, disable local HTTP, and disable
Unix socket server. Use the options listed below to override the
default configuration.
@ -35,13 +37,13 @@ extends_documentation_fragment: eos
options:
state:
description:
- Set to started or stopped. A state of started will
enable EAPI access, and a state of stopped will
disable or shutdown all EAPI access.
- A state of I(started) will
enable eAPI access, and a state of I(stopped) will
disable or shutdown all eAPI access.
choices:
- started
- stopped
requred: false
required: false
default: started
http_port:
description:
@ -63,6 +65,9 @@ options:
- Enable HTTP server access.
required: false
default: true
choices:
- yes
- no
aliases:
- enable_http
https:
@ -70,6 +75,9 @@ options:
- Enable HTTPS server access.
required: false
default: true
choices:
- yes
- no
aliases:
- enable_https
local_http:
@ -77,6 +85,9 @@ options:
- Enable local HTTP server access.
required: false
default: false
choices:
- yes
- no
aliases:
- enable_local_http
socket:
@ -84,17 +95,20 @@ options:
- Enable Unix socket server access.
required: false
default: false
choices:
- yes
- no
aliases:
- enable_socket
"""
EXAMPLES = """
- name: Enable EAPI access with default configuration
- name: Enable eAPI access with default configuration
eos_eapi:
state: started
provider: {{ provider }}
- name: Enable EAPI with no HTTP, HTTPS at port 9443, local HTTP at port 80, and socket enabled
- name: Enable eAPI with no HTTP, HTTPS at port 9443, local HTTP at port 80, and socket enabled
eos_eapi:
state: started
http: false
@ -104,7 +118,7 @@ EXAMPLES = """
socket: yes
provider: {{ provider }}
- name: Shutdown EAPI access
- name: Shutdown eAPI access
eos_eapi:
state: stopped
provider: {{ provider }}
@ -180,7 +194,7 @@ def config_server(module):
if not config.get('enabled'):
if state == 'started':
# turn on eapi access
# turn on eAPI access
commands.append('no shutdown')
result['changed'] = True
else:
@ -188,7 +202,7 @@ def config_server(module):
return result
if config.get('enabled') and state == 'stopped':
# turn off eapi access and exit
# turn off eAPI access and exit
commands.append('shutdown')
result['changed'] = True
result['commands'] = commands
@ -257,7 +271,7 @@ def main():
socket=dict(aliases=['enable_socket'], default=False, type='bool'),
local_http=dict(aliases=['enable_local_http'], default=False, type='bool'),
# Only allow use of transport cli when coniguring EAPI
# Only allow use of transport cli when configuring eAPI
transport=dict(required=True, choices=['cli'])
)

@ -23,9 +23,9 @@ author: "Peter sprygada (@privateip)"
short_description: Manage Arista EOS device configurations
description:
- Manages network device configurations over SSH or eAPI. This module
allows implementors to work with the device running-config. It
allows implementers to work with the device running-config. It
provides a way to push a set of commands onto a network device
by evaluting the current running-config and only pushing configuration
by evaluating the current running-config and only pushing configuration
commands that are not already configured. The config source can
be a set of commands or a template.
extends_documentation_fragment: eos
@ -49,9 +49,9 @@ options:
include_defaults:
description:
- By default when the M(eos_template) connects to the remote
device to retrieve the configuration it will issue the `show
running-config` command. If this option is set to True then
the issued command will be `show running-config all`
device to retrieve the configuration it will issue the C(show
running-config) command. If this option is set to True then
the issued command will be C(show running-config all).
required: false
default: false
choices: ['yes', 'no']
@ -69,8 +69,7 @@ options:
- This argument will cause the provided configuration to be replaced
on the destination node. The use of the replace argument will
always cause the task to set changed to true and will implies
I(force) is true. This argument is only valid with I(transport)
is eapi.
C(force=true). This argument is only valid with C(transport=eapi).
required: false
default: false
choices: ['yes', 'no']
@ -81,23 +80,23 @@ options:
against the contents of source. There are times when it is not
desirable to have the task get the current running-config for
every task in a playbook. The I(config) argument allows the
implementer to pass in the configuruation to use as the base
config for comparision.
implementer to pass in the configuration to use as the base
config for comparison.
required: false
default: null
"""
EXAMPLES = """
- name: push a configuration onto the device
- name: Push a configuration onto the device
eos_template:
src: config.j2
- name: forceable push a configuration onto the device
- name: Forceable push a configuration onto the device
eos_template:
src: config.j2
force: yes
- name: provide the base configuration for comparision
- name: Provide the base configuration for comparison
eos_template:
src: candidate_config.txt
config: current_config.txt

Loading…
Cancel
Save