AnsiblePilot — Master Ansible Automation
AnsiblePilot is the leading resource for learning Ansible automation, DevOps, and infrastructure as code. Browse over 1,100 tutorials covering Ansible modules, playbooks, roles, collections, and real-world examples. Whether you are a beginner or an experienced engineer, our step-by-step guides help you automate Linux, Windows, cloud, containers, and network infrastructure.
Popular Topics
About Luca Berton
Luca Berton is an Ansible automation expert, author of "Ansible for VMware by Examples" and "Ansible for Kubernetes by Example" published by Apress, and creator of the Ansible Pilot YouTube channel. He shares practical automation knowledge through tutorials, books, and video courses to help IT professionals and DevOps engineers master infrastructure automation.
How to install Ansible in CentOS 9 Stream - Ansible install — Video Tutorial
Updated 2026 guide to install Ansible on CentOS 9 Stream using EPEL and pip.
What You'll Learn
- How to install Ansible in CentOS Stream 9
- Links
- code
- execution
- before execution
- after execution
- Conclusion
- Related Articles
Full Tutorial Content
How to install Ansible in CentOS Stream version 9.
Today we're going to talk about the easier way to install and maintain Ansible inside CentO Stream version 9 using the system AppStream repository.
I'm Luca Berton and welcome to today's episode of Ansible Pilot
How to install Ansible in CentOS Stream 9
- `ansible-core` in system AppStream repository
- use Extra Packages for Enterprise Linux - EPEL Next additional packages for CentOS Stream
The easier way to install and maintain Ansible inside CentOS Stream version 9 is using the system AppStream repository.
Another way is to use the additional EPEL Next repository. This repository is maintained by the Fedora Special Interest Group and that manages a high-quality set of additional packages for CentOS Stream, similar to Extra Packages for Enterprise Linux (EPEL) additional packages target for Red Hat Enterprise Linux (RHEL), CentOS, and Scientific Linux (SL) and Oracle Linux (OL).
See also:
[Ansible terminology - ansible vs ansible-core packages](/articles/ansible-terminology-ansible-vs-ansible-core-packages).
Links
- [CentOS Stream Download](https://www.centos.org/centos-stream/)
- [EPEL 9 is now available](https://communityblog.fedoraproject.org/epel-9-is-now-available/)
- [Introducing CentOS Stream 9](https://blog.centos.org/2021/12/introducing-centos-stream-9/)
- [Extra Packages for Enterprise Linux (EPEL)](https://docs.fedoraproject.org/en-US/epel/)
## Playbook
Install Ansible in CentOS Stream version 9 via AppStream system repository.
code
- Install-Ansible-CentOS-Stream9.sh
```bash
#!/bin/bash
sudo dnf install ansible-core
```
execution
```bash
$ ssh devops@centos-stream.example.com
[devops@centos-stream ~]$ sudo su
[root@centos-stream devops]# cat /etc/redhat-release
CentOS Stream release 9
[root@centos-stream devops]# cat /etc/os-release
NAME="CentOS Stream"
VERSION="9"
ID="centos"
ID_LIKE="rhel fedora"
VERSION_ID="9"
PLATFORM_ID="platform:el9"
PRETTY_NAME="CentOS Stream 9"
ANSI_COLOR="0;31"
CPE_NAME="cpe:/o:centos:centos:9"
HOME_URL="https://centos.org/"
BUG_REPORT_URL="https://bugzilla.redhat.com/"
REDHAT_SUPPORT_PRODUCT="Red Hat Enterprise Linux 9"
REDHAT_SUPPORT_PRODUCT_VERSION="CentOS Stream"
[root@centos-stream devops]# hostnamectl
Static hostname: centos-stream.example.com
Icon name: computer-vm
Chassis: vm
Machine ID: 27ac33d81e2a400cbdaf6ae0b2b82e1d
Boot ID: 4060493b76fc4cc680defa0ffe99af41
Virtualization: oracle
Operating System: CentOS Stream 9
CPE OS Name: cpe:/o:centos:centos:9
Kernel: Linux 5.14.0-17.el9.x86_64
Architecture: x86-64
Hardware Vendor: innotek GmbH
Hardware Model: VirtualBox
[root@centos-stream devops]# dnf search ansible
Updating Subscription Management repositories.
Unable to read consumer identity
This system is not registered with an entitlement server. You can use subscription-manager to register.
CentOS Stream 9 - BaseOS 1
About This Tutorial
- Author: Luca Berton
- Difficulty: Beginner
- Read time: 9 min
- Category: installation
Read the full written article: How to install Ansible in CentOS 9 Stream - Ansible install