Prerequisites:
- Python 2.7 or Python 3.5
- pip
- setuptools 20.0.0+
Ansible Container relies upon supported container engines for building, running, and deploying your project. Currently supported engines are:
docker
- The Docker Enginek8s
- Kubernetes, on a remote service or in a local installation using MiniKubeopenshift
- Red Hat OpenShift, on a remote service or in a local installation using MiniShift
The simplest way to install Ansible Container is with the pip
command, such as:
$ sudo pip install ansible-container
If you do not have root privileges, you'll need to use a virtualenv
to create a Python sandbox:
$ virtualenv venv
$ source venv/bin/activate
$ pip install ansible-container
You'll need to run the activate
script in each shell session prior to invoking ansible-container
.
See the virtualenv docs for details.
If you'd like to run the bleeding edge version of Ansible Container, you can obtain it from our Github repository.
Prerequisites:
- All of the prerequisites listed in :ref:`getting_ansible_container`
- git
Clone the repo:
$ git clone https://github.com/ansible/ansible-container.git
We recommend that you use a Python Virtualenv to sandbox your installation. See the virtualenv docs for instructions.
It's again best to use pip
to install the cloned code:
$ cd ansible-container
$ pip install -e .
If you run into the following error, you likely have an older version of setuptools installed:
Traceback (most recent call last):
File "./setup.py", line 11, in <module>
packages=find_packages(include='container.*'),
TypeError: find_packages() got an unexpected keyword argument 'include'
Use the following to upgrade to the latest release, and then run the install command again:
$ pip install --upgrade setuptools
You may need to run the above command with sudo
if you're not using a virtualenv
.