Linux 通过ansible获取yum更新列表失败
味精:Linux 通过ansible获取yum更新列表失败,linux,ansible,yum,Linux,Ansible,Yum,味精: 在2.7.5版本上也有相同的问题。这似乎是缩进错误寄存器必须与yum位于同一列 ansible --version ansible 2.6.5 请将yml内容格式化为代码,以便我们可以看到您剧本的实际格式。 Unsupported parameters for (yum) module: register Supported parameters include: allow_downgrade, bugfix, conf_file, disable_gpg_check, disa
在
2.7.5版本上也有相同的问题。这似乎是缩进错误<代码>寄存器
必须与yum位于同一列
ansible --version
ansible 2.6.5
请将yml
内容格式化为代码,以便我们可以看到您剧本的实际格式。
Unsupported parameters for (yum) module: register Supported parameters
include: allow_downgrade, bugfix, conf_file, disable_gpg_check,
disable_plugin, disablerepo, enable_plugin, enablerepo, exclude,
install_repoquery, installroot, list, name, security, skip_broken, state,
update_cache, update_only, validate_certs
to retry, use:
ansible --version
ansible 2.6.5
- hosts: all
gather_facts: false
become: yes
user: username
tasks:
- name: List Available Patches (Non-Kernel)
yum:
list: updates
update_cache: true
exclude: kernel*
register: yumoutput
- debug: msg="{{ inventory_hostname}} {{ yumoutput.results }}"