community.general.onyx_ntp (0.1.1) — module

Manage NTP general configurations and ntp keys configurations on Mellanox ONYX network devices

Authors: Sara-Touqan (@sarato)

preview | supported by community

Install collection

Install with ansible-galaxy collection install community.general:==0.1.1


Add to requirements.yml

  collections:
    - name: community.general
      version: 0.1.1

Description

This module provides declarative management of NTP & NTP Keys on Mellanox ONYX network devices.

Usage examples

  • Success
    Steampunk Spotter scan finished with no errors, warnings or hints.
- name: configure NTP
  onyx_ntp:
    state: enabled
    authenticate_state: enabled
    ntp_authentication_keys:
            - auth_key_id: 1
              auth_key_encrypt_type: md5
              auth_key_password: 12345
              auth_key_state: absent
    trusted_keys: 1,2,3

Inputs

    
state:
    choices:
    - enabled
    - disabled
    description:
    - State of the NTP configuration.
    type: str

trusted_keys:
    description:
    - List of ntp trusted keys
    type: list

authenticate_state:
    choices:
    - enabled
    - disabled
    description:
    - State of the NTP authentication configuration.
    type: str

ntp_authentication_keys:
    description:
    - List of ntp authentication keys
    suboptions:
      auth_key_encrypt_type:
        choices:
        - md5
        - sha1
        description:
        - encryption type used to configure ntp authentication key.
        required: true
        type: str
      auth_key_id:
        description:
        - Configures ntp key-id, range 1-65534
        required: true
        type: int
      auth_key_password:
        description:
        - password used for ntp authentication key.
        required: true
        type: str
      auth_key_state:
        choices:
        - present
        - absent
        description:
        - Used to decide if you want to delete given ntp key or not
        type: str
    type: list

Outputs

commands:
  description: The list of configuration mode commands to send to the device
  returned: always.
  sample:
  - ntp enable
  - ntp disable
  - ntp authenticate
  - no ntp authenticate
  - ntp authentication-key 1 md5 12345
  - no ntp authentication-key 1
  - ntp trusted-key 1,2,3
  type: list