Ansible 2.0 -- the "new" correct way to update??

As you may recall, I had to uninstall Ansible 1.9.4 in order to install Ansible 2.0.0.0. But now, upgrading to Ansible 2.0.0.2 succeeds but has no effect.
I’m on MacOSX El Capitan (10.11.2)

$ ansible --version ansible 2.0.0.0 config file = configured module search path = Default w/o overrides $

$ sudo -H pip install --upgrade ansible --user python Password: Collecting ansible Downloading ansible-2.0.0.2.tar.gz (1.5MB) 100% |################################| 1.5MB 258kB/s Requirement already up-to-date: python in /System/Library/Frameworks/Python.framework/Versions/2.7/lib/python2.7/lib-dynload Requirement already up-to-date: paramiko in /Library/Python/2.7/site-packages (from ansible) Requirement already up-to-date: jinja2 in /Library/Python/2.7/site-packages (from ansible) Requirement already up-to-date: PyYAML in /Library/Python/2.7/site-packages (from ansible) Collecting setuptools (from ansible) Using cached setuptools-19.2-py2.py3-none-any.whl Requirement already up-to-date: pycrypto>=2.6 in /Library/Python/2.7/site-packages (from ansible) Requirement already up-to-date: ecdsa>=0.11 in /Library/Python/2.7/site-packages (from paramiko->ansible) Requirement already up-to-date: MarkupSafe in /Library/Python/2.7/site-packages (from jinja2->ansible) Installing collected packages: setuptools, ansible Running setup.py install for ansible Successfully installed ansible-2.0.0.2 setuptools-1.1.6 $

$ ansible --version ansible 2.0.0.0 config file = configured module search path = Default w/o overrides $

What is the correct way to handle updates going forward?

The problem is with a new 'protection' in OS X 'el capitan' which
breaks the pip update, this is not restricted to Ansible but to any
pip package you install with sudo.

https://github.com/ansible/ansible/issues/13820

Ok, so going forward, it appears that I need to uninstall the old version, and then install the new version.

There is no need to use sudo with --user. You should pick one or the other.

sudo will install as root into /usr/local/bin, whereas --user installed into your home directory under .local/

I ended up going down the virtualenv path for this. Covers OSX as well as Linux. I went this path in order to have the ability to switch back and forth between versions in order to test functionality between 1.9.x and 2.0

http://everythingshouldbevirtual.com/ansible-setting-up-an-ansible-control-machine-part-1

It seems to me that the issue revolves around upgrading setuptools. I’m totally okay with uninstalling and reinstalling Ansible but I am curious about “better” ways of upgrading if people would like to share them.

I switched over to Homebrew to install current release of Ansible (after removing the prior release with pip).

I echo Chris’s post. The docs say for yum the command is sudo yum install ansible. But that still only gets you 1.9.4. When will Ansible update YUM with 2.0???

Thank you Slim…the info in your post worked. I now have 2.0. :-}

Glenn, the new 2.0 rpm packages are in the epel-test channel and will stay there for a while. That’s kind of a policy with the epel project.

If they would push the package to the main epel repository it would break all those setups that are not ready yet for the update.