On 01.05.2018 12:29, Varun Chopra wrote:
Hi,
I'm trying to install Ansible 2.3 on a server with 2.5 already present.
I built and installed virtualenv and download ansible 2.3 and initiated
a
virtualenv using source ./hacking/env-setup
Will this new installation hinder with the 2.5 install in any way?
How long does the virtualenv exist? How do I close the virtualenv and
go
back to using 2.5?
There is a lot of guides about Python virtual environment that you can
read to get this information.
But I can give you this as an example
user@gh:~$ virtualenv ~/ansible2.3
Running virtualenv with interpreter /usr/bin/python2
New python executable in /home/user/ansible2.3/bin/python2
Also creating executable in /home/user/ansible2.3/bin/python
Installing setuptools, pkg_resources, pip, wheel...done.
(ansible2.3) user@gh:~$ pip install "ansible<2.4"
Collecting ansible<2.4
Downloading
https://files.pythonhosted.org/packages/d4/61/4080493544ecec71e770a20aa94cbd35a382813fac4fddb97573ae50bc7d/ansible-2.3.3.0.tar.gz
(4.2MB)
Successfully built ansible PyYAML pycrypto MarkupSafe pycparser
Installing collected packages: MarkupSafe, jinja2, PyYAML, pycparser,
cffi, enum34, idna, asn1crypto, six, ipaddress, cryptography, pynacl,
pyasn1, bcrypt, paramiko, pycrypto, ansible
Successfully installed MarkupSafe-1.0 PyYAML-3.12 ansible-2.3.3.0
asn1crypto-0.24.0 bcrypt-3.1.4 cffi-1.11.5 cryptography-2.2.2
enum34-1.1.6 idna-2.6 ipaddress-1.0.22 jinja2-2.10 paramiko-2.4.1
pyasn1-0.4.2 pycparser-2.18 pycrypto-2.6.1 pynacl-1.2.1 six-1.11.0
(ansible2.3) user@gh:~$ ansible --version
ansible 2.3.3.0
config file = /etc/ansible/ansible.cfg
configured module search path = Default w/o overrides
python version = 2.7.14 (default, Sep 23 2017, 22:06:14) [GCC 7.2.0]
(ansible2.3) user@gh:~$ deactivate
user@gh:~$ ansible --version
ansible 2.5.2
config file = /etc/ansible/ansible.cfg
configured module search path =
[u'/home/user/.ansible/plugins/modules',
u'/usr/share/ansible/plugins/modules']
ansible python module location =
/usr/lib/python2.7/dist-packages/ansible
executable location = /usr/bin/ansible
python version = 2.7.14 (default, Sep 23 2017, 22:06:14) [GCC 7.2.0]
user@gh:~$ source ~/ansible2.3/bin/activate
(ansible2.3) user@gh:~$ ansible --version
ansible 2.3.3.0
config file = /etc/ansible/ansible.cfg
configured module search path = Default w/o overrides
python version = 2.7.14 (default, Sep 23 2017, 22:06:14) [GCC 7.2.0]
--
Kai Stian Olstad
--
You received this message because you are subscribed to the Google Groups "Ansible
Project" group.
To unsubscribe from this group and stop receiving emails from it, send an email
to ansible-project+unsubscr...@googlegroups.com.
To post to this group, send email to ansible-project@googlegroups.com.
To view this discussion on the web visit
https://groups.google.com/d/msgid/ansible-project/b0782c33064d7c13b458010f36dab9e8%40olstad.com.
For more options, visit https://groups.google.com/d/optout.