2016-04-15 42 views
1

運行Debian傑西如何幹淨地卸載ansible

我使用以下步驟安裝Ansible:

apt-get update 
sudo apt-get install python-yaml python-pip python-jinja2 python-paramiko pip 
git clone https://github.com/ansible/ansible.git 
cd ansible 
git submodule update --init --recursive 
sudo make install 

有沒有乾淨地卸載Ansible不涉及通過我的目錄樹和刪除篩選?

目的是重新安裝Ansible版本1.9,而不是最新的2.1.0

回答

1

沒有在源代碼回購目錄列表,告訴你哪個目錄(和文件)創建的。這是用於構建.deb軟件包,但你可以很容易地使用它周圍的其他方法:

packaging/debian/ansible.dirs

1

如果您已經安裝在RedHat的CentOS的系統 你可以做下面ansible乾淨和類似卸載命令爲基於Ubuntu Debian的系統

rpm -qa | grep ansible | xargs rpm -e

rpm -qa | grep -i epel | xargs的轉-e

其他百勝刪除ansible

0

我已經建立ansible 2.1.1從源代碼,然後想用yum降級到2.1.0。我學到的技巧是去/lib/python2.7/site-packages並刪除ansible-2.1.1.0-py2.7.egg-info目錄。在我的情況下,使用yum正確地將文件添加到/ etc/ansible和/ usr/bin,但只要舊的(新版本號)雞蛋在那裏,然後ansible --version繼續顯示較新的版本號。