How to install Ansible in the latest Ubuntu 21.10.
Today we're going to talk about the easier way to install and maintain Ansible inside Ubuntu 21.10 with the distribution tools.
I'm Luca Berton and welcome to today's episode of Ansible Pilot.
How to install Ansible in Ubuntu 21.10
- universe
- PPA
Today we're talking about How to install Ansible in Ubuntu 21.10?
We're going to see the easy way to install and maintain Ansible inside Ubuntu with the distribution tools.
We are going to see how to install Ansible in two different ways.
The first method to install Ansible is using the universe repository, the default that you get after installation.
The main advantage of using the universe repository is that you don't require any external repository.
And the second method to install Ansible is using the PPA repository. Please bear in mind that adding an additional repository has a different quality assurance of software.
Playbook
Install Ansible in Ubuntu 21.10 with universe and PPA
universe code
``bash
#!/bin/bash
sudo apt update
sudo apt install ansible
`
universe execution
``bash
$ ssh [email protected]
The authenticity of host 'ubuntu2110.example.com (192.168.0.203)' can't be established.
ECDSA key fingerprint is SHA256:v0BXVb5/2XfPoqb/bk70pOsw0tvVh/THiqblJnCXhg4.
Are you sure you want to continue connecting (yes/no/[fingerprint])? yes
Warning: Permanently added 'ubuntu2110.example.com,192.168.0.203' (ECDSA) to the list of known hosts.
Welcome to Ubuntu 21.10 (GNU/Linux 5.13.0-19-generic x86_64)
* Documentation: https://help.ubuntu.com
* Management: https://landscape.canonical.com
* Support: https://ubuntu.com/advantage
System information as of Mon Nov 1 15:30:37 UTC 2021
System load: 0.31 Processes: 102
Usage of /: 3.2% of 38.71GB Users logged in: 0
Memory usage: 17% IPv4 address for enp0s3: 10.0.2.15
Swap usage: 0% IPv4 address for enp0s8: 192.168.0.203
0 updates can be applied immediately.
The list of available updates is more than a week old.
To check for new updates run: sudo apt update
The programs included with the Ubuntu system are free software;
the exact distribution terms for each program are described in the
individual files in /usr/share/doc/*/copyright.
Ubuntu comes with ABSOLUTELY NO WARRANTY, to the extent permitted by
applicable law.
$ sudo su
root@ubuntu:/home/devops# lsb_release -a
No LSB modules are availa