ansible / ansible.builtin / v2.7.16 / module / nxos_ntp Manages core NTP configuration. | "added in version" 2.2 of ansible.builtin" Authors: Jason Edelman (@jedelman8) preview | supported by networkansible.builtin.nxos_ntp (v2.7.16) — module
pip
Install with pip install ansible==2.7.16
Manages core NTP configuration.
# Set NTP Server with parameters - nxos_ntp: server: 1.2.3.4 key_id: 32 prefer: enabled host: "{{ inventory_hostname }}" username: "{{ un }}" password: "{{ pwd }}"
peer: description: - Network address of NTP peer. state: choices: - present - absent default: present description: - Manage the state of the resource. key_id: description: - Authentication key identifier to use with given NTP server or peer or keyword 'default'. prefer: choices: - enabled - disabled description: - Makes given NTP server or peer the preferred NTP server or peer for the device. server: description: - Network address of NTP server. vrf_name: description: - Makes the device communicate with the given NTP server or peer over a specific VRF or keyword 'default'. source_int: description: - Local source interface from which NTP messages are sent. Must be fully qualified interface name or keyword 'default' source_addr: description: - Local source address from which NTP messages are sent or keyword 'default'
changed: description: check to see if a change was made on the device returned: always sample: true type: boolean end_state: description: k/v pairs of ntp info after module execution returned: always sample: address: 192.0.2.2 key_id: '48' peer_type: server prefer: enabled source: 192.0.2.3 source_type: source type: dict existing: description: - k/v pairs of existing ntp server/peer returned: always sample: address: 192.0.2.2 key_id: '32' peer_type: server prefer: enabled source: ethernet2/1 source_type: source-interface type: dict proposed: description: k/v pairs of parameters passed into module returned: always sample: address: 192.0.2.2 key_id: '48' peer_type: server prefer: enabled source: 192.0.2.3 source_type: source type: dict updates: description: command sent to the device returned: always sample: - ntp server 192.0.2.2 prefer key 48 - no ntp source-interface ethernet2/1 - ntp source 192.0.2.3 type: list