安装方式

 ansible安装常用两种方式,yum安装pip程序安装。下面我们来详细介绍一下这两种安装方式。

yum安装

1.安装epel源

yum install wget -y
wget -P /etc/yum.repos.d/epel.repo http://mirrors.aliyun.com/repo/epel-7.repo

或者

yum install -y epel-release

2.安装ansible

yum install ansible –y

pip安装

1.安装pip
yum install python2-pip

2.安装ansible
pip install ansible