New in version 2.4.
parameter | required | default | choices | comments |
---|---|---|---|---|
area | yes | Ospf area associated with this ospf process. Valid values are a string, formatted as an IP address (i.e. "0.0.0.0") or as an integer between 1 and 4294967295. | ||
auth_key_id | no | Authentication key id when auth_mode is 'hmac-sha256', 'md5' or 'hmac-md5. Valid value is an integer is in the range from 1 to 255. | ||
auth_mode | no |
| Specifies the authentication type. | |
auth_text_md5 | no | Specifies a password for MD5, HMAC-MD5, or HMAC-SHA256 authentication. The value is a string of 1 to 255 case-sensitive characters, spaces not supported. | ||
auth_text_simple | no | Specifies a password for simple authentication. The value is a string of 1 to 8 characters. | ||
cost | no | The cost associated with this interface. Valid values are an integer in the range from 1 to 65535. | ||
dead_interval | no | Time interval an ospf neighbor waits for a hello packet before tearing down adjacencies. Valid values are an integer in the range from 1 to 235926000. | ||
hello_interval | no | Time between sending successive hello packets. Valid values are an integer in the range from 1 to 65535. | ||
interface | yes | Full name of interface, i.e. 40GE1/0/10. | ||
process_id | yes | Specifies a process ID. The value is an integer ranging from 1 to 4294967295. | ||
silent_interface | no | Setting to true will prevent this interface from receiving HELLO packets. Valid values are 'true' and 'false'. | ||
state | no | present |
| Determines whether the config should be present or not on the device. |
- name: eth_trunk module test hosts: cloudengine connection: local gather_facts: no vars: cli: host: "{{ inventory_hostname }}" port: "{{ ansible_ssh_port }}" username: "{{ username }}" password: "{{ password }}" transport: cli tasks: - name: Enables OSPF and sets the cost on an interface ce_interface_ospf: interface: 10GE1/0/30 process_id: 1 area: 100 cost: 100 provider: '{{ cli }}' - name: Sets the dead interval of the OSPF neighbor ce_interface_ospf: interface: 10GE1/0/30 process_id: 1 area: 100 dead_interval: 100 provider: '{{ cli }}' - name: Sets the interval for sending Hello packets on an interface ce_interface_ospf: interface: 10GE1/0/30 process_id: 1 area: 100 hello_interval: 2 provider: '{{ cli }}' - name: Disables an interface from receiving and sending OSPF packets ce_interface_ospf: interface: 10GE1/0/30 process_id: 1 area: 100 silent_interface: true provider: '{{ cli }}'
Common return values are documented here Return Values, the following are the fields unique to this module:
name | description | returned | type | sample |
---|---|---|---|---|
end_state | k/v pairs of configuration after module execution | verbose mode | dict | {'cost': '100', 'area': '0.0.0.100', 'silent_interface': 'false', 'auth_mode': 'none', 'dead_interval': '40', 'process_id': '6', 'hello_interval': '10', 'interface': '10GE1/0/30'} |
changed | check to see if a change was made on the device | always | boolean | True |
updates | commands sent to the device | always | list | ['interface 10GE1/0/30', 'ospf enable 1 area 0.0.0.100', 'ospf cost 100'] |
proposed | k/v pairs of parameters passed into module | verbose mode | dict | {'interface': '10GE1/0/30', 'process_id': '1', 'cost': '100', 'area': '0.0.0.100'} |
existing | k/v pairs of existing configuration | verbose mode | dict | {'process_id': '1', 'area': '0.0.0.100'} |
This module is flagged as preview which means that it is not guaranteed to have a backwards compatible interface.
For help in developing on modules, should you be so inclined, please read Community Information & Contributing, Testing Ansible and Developing Modules.
© 2012–2017 Michael DeHaan
© 2017 Red Hat, Inc.
Licensed under the GNU General Public License version 3.
https://docs.ansible.com/ansible/latest/ce_interface_ospf_module.html