summaryrefslogtreecommitdiff
path: root/plugins
diff options
context:
space:
mode:
authorRohit Thakur <rohitthakur2590@outlook.com>2020-05-08 13:14:12 +0530
committerRohit Thakur <rohitthakur2590@outlook.com>2020-05-08 13:14:12 +0530
commit45715027fec488a74f7942cbc647ce7a6e0c69ed (patch)
tree6f72763224aa225a7718ddee3fabc50159e17570 /plugins
parentbf9a91b4859e07c40b0a6aeb64b8ef6096af41b1 (diff)
downloadvyos-ansible-collection-45715027fec488a74f7942cbc647ce7a6e0c69ed.tar.gz
vyos-ansible-collection-45715027fec488a74f7942cbc647ce7a6e0c69ed.zip
test cases updated
Signed-off-by: Rohit Thakur <rohitthakur2590@outlook.com>
Diffstat (limited to 'plugins')
-rw-r--r--plugins/modules/vyos_firewall_rules.py36
1 files changed, 18 insertions, 18 deletions
diff --git a/plugins/modules/vyos_firewall_rules.py b/plugins/modules/vyos_firewall_rules.py
index 687eb03..9c2e832 100644
--- a/plugins/modules/vyos_firewall_rules.py
+++ b/plugins/modules/vyos_firewall_rules.py
@@ -37,8 +37,9 @@ ANSIBLE_METADATA = {
}
DOCUMENTATION = """module: vyos_firewall_rules
-short_description: This configures and manages attributes of firewall_rules resorce module
+short_description: Firewall rules resource module
description: This module manages firewall rule-set attributes on VyOS devices
+version_added: "1.0.0"
notes:
- Tested against VyOS 1.1.8 (helium).
- This module works with connection C(network_cli). See L(the VyOS OS Platform Options,../network/user_guide/platform_vyos.html).
@@ -397,13 +398,12 @@ options:
type: str
running_config:
description:
- - The module, by default, will connect to the remote device and retrieve the current
- running-config to use as a base for comparing 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(running_config) argument allows the implementer
- to pass in the configuration to use as the base config for comparison. This
- value of this option should be the output received from device by executing
- command C(show configuration commands | grep 'firewall'
+ - This option is used only with state I(parsed).
+ - The value of this option should be the output received from the VyOS device by executing
+ the command B(show configuration commands | grep firewall).
+ - The state I(parsed) reads the configuration from C(running_config) option and transforms
+ it into Ansible structured data as per the resource module's argspec and the value is then
+ returned in the I(parsed) key within the result.
type: str
state:
description:
@@ -437,7 +437,7 @@ EXAMPLES = """
# set firewall name Downlink rule 502 ipsec 'match-ipsec'
#
- name: Delete attributes of given firewall rules.
- vyos_firewall_rules:
+ vyos.vyos.vyos_firewall_rules:
config:
- afi: ipv4
rule_sets:
@@ -514,7 +514,7 @@ EXAMPLES = """
#
- name: Delete attributes of given firewall rules.
- vyos_firewall_rules:
+ vyos.vyos.vyos_firewall_rules:
config:
- afi: ipv4
state: deleted
@@ -611,7 +611,7 @@ EXAMPLES = """
# set firewall name Downlink rule 502 ipsec 'match-ipsec'
#
- name: Delete attributes of given firewall rules.
- vyos_firewall_rules:
+ vyos.vyos.vyos_firewall_rules:
config:
state: deleted
#
@@ -666,7 +666,7 @@ EXAMPLES = """
# set firewall group address-group 'inbound'
#
- name: Merge the provided configuration with the exisiting running configuration
- vyos_firewall_rules:
+ vyos.vyos.vyos_firewall_rules:
config:
- afi: 'ipv6'
rule_sets:
@@ -885,7 +885,7 @@ EXAMPLES = """
# set firewall name INBOUND rule 103 state related 'enable'
#
- name: Replace device configurations of listed firewall rules with provided configurations
- vyos_firewall_rules:
+ vyos.vyos.vyos_firewall_rules:
config:
- afi: 'ipv6'
rule_sets:
@@ -1067,7 +1067,7 @@ EXAMPLES = """
# set firewall name INBOUND rule 104 ipsec 'match-none'
#
- name: Overrides all device configuration with provided configuration
- vyos_firewall_rules:
+ vyos.vyos.vyos_firewall_rules:
config:
- afi: 'ipv4'
rule_sets:
@@ -1218,7 +1218,7 @@ EXAMPLES = """
# set firewall name INBOUND rule 103 state related 'enable'
#
- name: Gather listed firewall rules with provided configurations
- vyos_firewall_rules:
+ vyos.vyos.vyos_firewall_rules:
config:
state: gathered
#
@@ -1333,7 +1333,7 @@ EXAMPLES = """
#
#
- name: Render the commands for provided configuration
- vyos_firewall_rules:
+ vyos.vyos.vyos_firewall_rules:
config:
- afi: 'ipv6'
rule_sets:
@@ -1403,8 +1403,8 @@ EXAMPLES = """
# Using parsed
#
#
-- name: Render the commands for provided configuration
- vyos_firewall_rules:
+- name: Parsed the provided input commands.
+ vyos.vyos.vyos_firewall_rules:
running_config:
"set firewall group address-group 'inbound'
set firewall name Downlink default-action 'accept'