dellemc.enterprise_sonic.sonic_aaa 模块 – 管理 AAA 及其参数
注意
此模块是 dellemc.enterprise_sonic 集合 (版本 2.5.1) 的一部分。
如果您正在使用 ansible 包,则可能已经安装了此集合。它不包含在 ansible-core 中。要检查它是否已安装,请运行 ansible-galaxy collection list。
要安装它,请使用:ansible-galaxy collection install dellemc.enterprise_sonic。
要在 playbook 中使用它,请指定:dellemc.enterprise_sonic.sonic_aaa。
dellemc.enterprise_sonic 1.1.0 中的新增功能
概要
- 此模块用于管理运行 Enterprise SONiC 的设备上的 aaa 参数配置。 
注意
此模块具有相应的 action 插件。
参数
| 参数 | 注释 | 
|---|---|
| 指定 aaa 相关的配置 | |
| 指定 aaa 身份验证所需的配置 | |
| 指定 aaa 身份验证所需的数据 | |
| 指定直通状态 选项 
 | |
| 指定 aaa 身份验证的方法 选项 
 | |
| 启用或禁用本地身份验证 选项 
 | |
| 指定要对设备上配置的 aaa 参数执行的操作。 如果为 merged,则输入配置将与设备上现有的 aaa 配置合并。 如果为 deleted,则将从设备中删除现有的 aaa 配置。 如果为 replaced,则现有的 aaa 配置将被提供的配置替换。 如果为 overridden,则现有的 aaa 配置将被提供的配置覆盖。 选项 
 | 
备注
注意
- 针对戴尔科技的 Enterprise SONiC 发行版进行了测试。 
- 支持 - check_mode。
示例
# Using deleted
#
# Before state:
# -------------
#
# do show aaa
# AAA Authentication Information
# ---------------------------------------------------------
# failthrough  : True
# login-method : local
- name: Delete aaa configurations
  dellemc.enterprise_sonic.sonic_aaa:
    config:
      authentication:
        data:
          local: True
    state: deleted
# After state:
# ------------
#
# do show aaa
# AAA Authentication Information
# ---------------------------------------------------------
# failthrough  : True
# login-method :
# Using deleted
#
# Before state:
# -------------
#
# do show aaa
# AAA Authentication Information
# ---------------------------------------------------------
# failthrough  : True
# login-method : local
- name: Delete aaa configurations
  dellemc.enterprise_sonic.sonic_aaa:
    config:
    state: deleted
# After state:
# ------------
#
# do show aaa
# AAA Authentication Information
# ---------------------------------------------------------
# failthrough  :
# login-method :
# Using merged
#
# Before state:
# -------------
#
# do show aaa
# AAA Authentication Information
# ---------------------------------------------------------
# failthrough  : False
# login-method :
- name: Merge aaa configurations
  dellemc.enterprise_sonic.sonic_aaa:
    config:
      authentication:
        data:
          local: true
          fail_through: true
    state: merged
# After state:
# ------------
#
# do show aaa
# AAA Authentication Information
# ---------------------------------------------------------
# failthrough  : True
# login-method : local
# Using replaced
#
# Before state:
# -------------
#
# do show aaa
# AAA Authentication Information
# ---------------------------------------------------------
# failthrough  : False
# login-method : local, radius
- name: Replace aaa configurations
  dellemc.enterprise_sonic.sonic_aaa:
    config:
      authentication:
        data:
          group: ldap
          fail_through: true
    state: replaced
# After state:
# ------------
#
# do show aaa
# AAA Authentication Information
# ---------------------------------------------------------
# failthrough  : True
# login-method : local, ldap
# Using overridden
#
# Before state:
# -------------
#
# do show aaa
# AAA Authentication Information
# ---------------------------------------------------------
# failthrough  : False
# login-method : local, radius
- name: Override aaa configurations
  dellemc.enterprise_sonic.sonic_aaa:
    config:
      authentication:
        data:
          group: tacacs+
          fail_through: true
    state: overridden
# After state:
# ------------
#
# do show aaa
# AAA Authentication Information
# ---------------------------------------------------------
# failthrough  : True
# login-method : tacacs+
返回值
常见的返回值已在 此处 记录,以下是此模块独有的字段
| 键 | 描述 | 
|---|---|
| 生成的配置模型调用。 返回:发生更改时 示例: | |
| 生成的配置模型调用。 返回:当  示例: | |
| 模型调用之前的配置。 返回:始终返回 示例: | |
| 推送到远程设备的命令集。 返回:始终返回 示例: | 
