Building Ansible - linux-on-ibm-z/docs GitHub Wiki
Building Ansible
Below versions of Ansible are available in respective distributions at the time of creation of these build instructions:
- RHEL (8.8, 8.9, 8.10) have
8.3.0
- RHEL (9.2, 9.3, 9.4) have
7.7.0
- SLES 12 SP5 has
2.8.1
- SLES 15 SP5 have
2.9.27
- Ubuntu 20.04 has
2.9.6
- Ubuntu 22.04 has
2.10.8
- Ubuntu 23.10 has
7.7.0
- Ubuntu 24.04 has
9.2.0
The instructions provided below specify the steps to build Ansible latest version on Linux on IBM Z for the following distributions:
- RHEL (8.8, 8.9, 8.10, 9.2, 9.3, 9.4)
- SLES (12 SP5, 15 SP5)
- Ubuntu (20.04, 22.04, 23.10, 24.04)
General Notes:
-
When following the steps below please use a standard permission user unless otherwise specified.
-
A directory
/<source_root>/
will be referred to in these instructions, this is a temporary writable directory anywhere you'd like to place it.
Note: Ansible(v10.0.1) was verified at the time of creation of these instructions
Step 1: Install dependencies
-
RHEL (8.8, 8.9, 8.10, 9.2, 9.3, 9.4)
sudo yum install -y python3.11-devel python3.11-pip gcc openssl-devel
-
SLES 12 SP5
sudo zypper install -y openssl-devel gcc make gzip glibc-locale export LANG="en_US.UTF-8" export LC_ALL=en_US.UTF-8
-
SLES 15 SP5
sudo zypper install -y gcc make openssl-devel wget glibc-locale export LANG="en_US.UTF-8" export LC_ALL=en_US.UTF-8
-
Ubuntu (20.04, 22.04, 23.10, 24.04)
sudo apt update sudo apt install -y wget
-
Install Python version
3.12.x
(Ubuntu and SLES)- Instructions for building Python 3.12.x can be found here
Step 2: Install Ansible
pip3 install cryptography==3.3.2 # For all distros except RHEL distros
python3.11 -m pip install cryptography==3.3.2 # For RHEL distros
pip3 install ansible==10.0.1 # For all distros except RHEL distros
python3.11 -m pip install ansible==10.0.1 # For RHEL distros
Note: In case of an error sudo: pip3: command not found
on RHEL or SLES, run above command as sudo -H env PATH=$PATH pip3 install ...
instead of sudo pip3 install ...
.
Step 3: Verification (Optional)
Follow the official guide given here to verify the installation.