编辑文件 ~/.ansible.cfg

[defaults]
host_key_checking = False

看起来用着有点问题

用如下

ANSIBLE_HOST_KEY_CHECKING=False ansible all -m raw -a 'date'

或者,直接把变量放到 ~/.bashrc

# for ansible
ANSIBLE_HOST_KEY_CHECKING=False
Copyright © opschina.org 2017 with zzlyzq@gmail.com all right reserved,powered by Gitbook该文件修订时间: 2017-07-11 11:32:48

results matching ""

    No results matching ""