ansible安装 http://www.ansible.com.cn/ 1.1、有环境的情况下,直接yum,需要epel yum源 yum install epel-release -y yum -y install ansible 1.2、没有环境,可以先下载rpm到本地,然后上传到目标机安装 http://mirrors.aliyun.com/epel/7/x86_64/Packages mkdir -p /etc/packages/ yum install --downloadonly --downloaddir=/etc/packages/ ansible 依赖包: Installed: ansible.noarch 0:2.9.27-1.el7 Dependency Installed: PyYAML.x86_64 0:3.10-11.el7 python-babel.noarch 0:0.9.6-8.el7 python-jinja2.noarch 0:2.7.2-4.el7 python-markupsafe.x86_64 0:0.11-10.el7 python-paramiko.noarch 0:2.1.1-9.el7 python2-httplib2.noarch 0:0.18.1-3.el7 python2-jmespath.noarch 0:0.9 python2-cryptography.x86_64 0:1.7.2-2.el7 rpm -ql ansible.noarch 0:2.9.27-1.el7 |grep -vE "share|python2" /etc/ansible /etc/ansible/ansible.cfg /etc/ansible/hosts /etc/ansible/roles 2 源码包安装: ansible tar.gz包下载:https://releases.ansible.com/ansible/ ansible-2.9.9.tar.gz 模块包下载地址:https://pypi.org/ 3.依次解压、安装源码包文件 注:安装过程中请依次进行如下顺序安装 安装 setuptools unzip setuptools-41.0.1.zip cd setuptools-41.0.1 python setup.py install 安装pycrypto tar -xzf pycrypto-2.6.1.tar.gz cd pycrypto-2.6.1 python setup.py install 安装 PyYAML tar -xzf PyYAML-5.1.tar.gz cd PyYAML-5.1 python setup.py install 安装MarkupSafe tar -xzf MarkupSafe-1.1.1.tar.gz cd MarkupSafe-1.1.1 python setup.py install 安装Jinja2 tar -xzf Jinja2-2.10.1.tar.gz cd Jinja2-2.10.1 python setup.py install 安装ecdsa tar -xzf ecdsa-0.13.2.tar.gz cd ecdsa-0.13.2 python setup.py install 安装simplejson tar -xzf simplejson-3.16.0.tar.gz cd simplejson-3.16.0 python setup.py install 安装pycparser tar -xzf pycparser-2.19.tar.gz cd pycparser-2.19 python setup.py install 安装cffi tar -xzf cffi-1.12.3.tar.gz cd cffi-1.12.3 python setup.py install 安装ipaddress tar -xzf ipaddress-1.0.22.tar.gz cd ipaddress-1.0.22 python setup.py install 安装six tar -xzf six-1.12.0.tar.gz cd six-1.12.0 python setup.py install 安装asn1crypto tar -xzf asn1crypto-0.24.0.tar.gz cd asn1crypto-0.24.0 python setup.py install 安装pyasn1 tar -xzf pyasn1-0.4.5.tar.gz cd pyasn1-0.4.5 python setup.py install 安装PyNaCl tar -xzf PyNaCl-1.3.0.tar.gz cd PyNaCl-1.3.0 python setup.py install 安装cryptography tar -xzf cryptography-2.6.1.tar.gz cd cryptography-2.6.1 python setup.py install 安装paramiko tar -xzf paramiko-2.4.2.tar.gz cd paramiko-2.4.2 python setup.py install 安装ansible tar -xzf ansible-latest.tar.gz cd ansible-2.7.10/ python setup.py install 安装完成后,检查查看ansible版本 ansible --version
标签:tar,python,gz,cd,ansible,install,安装 From: https://www.cnblogs.com/skyzy/p/16890940.html