yum 安装 ansible

1、安装依赖

yum -y install python-setuptools python2-cryptography python-jinja2 python-cryptography

  

2、centos Base yum源中没有ansible的安装包,需替换yum 源

cd /etc/yum.repos.d/
mv CentOS-Base.repo CentOS-Base.repo.bak
wget -O epel.repohttp://mirrors.aliyun.com/repo/epel-6.repo

yum -y clean all --verbose
yum makecache
yum install ansible

#测试
ansible -m ping 192.168.1.104 -k

  

 

posted @ 2021-06-05 22:09  胖胖的小凉  阅读(494)  评论(0编辑  收藏  举报