Ansible刚安装完后执行报错

发布时间:2024年01月10日

1.

"msg": "Using a SSH password instead of a key is not possible because Host Key checking is enabled and sshpass does not support this. ?Please add this host's fingerprint to your known_hosts file to manage this host."

解决:

打开ansible.cfg文件位置,/etc/ansible/ansible.cfg

去掉注释即可
# uncomment this to disable SSH key host checking
host_key_checking = False

2.

[WARNING]: Platform linux on host ai_host_1 is using the discovered Python interpreter at /usr/bin/python, but future
installation of another Python interpreter could change this. See
https://docs.ansible.com/ansible/2.9/reference_appendices/interpreter_discovery.html for more information.?

解决:

在ansible.cfg的[defaults]部分添加

interpreter_python = auto_legacy_silent

文章来源:https://blog.csdn.net/red_sky_blue/article/details/135502344
本文来自互联网用户投稿,该文观点仅代表作者本人,不代表本站立场。本站仅提供信息存储空间服务,不拥有所有权,不承担相关法律责任。