0%

0/1 Lessons

Course Introduction

• 17min

0 / 2 lessons complete

IT Lab Setup

• 20min

0 / 3 lessons complete

Installing Ansible

• 35min

0 / 3 lessons complete

Managing your Ansible Inventory

• 2hr 6min

0 / 8 lessons complete

Ansible Basics

• 1hr 43min

0 / 9 lessons complete

Ansible Roles

• 2hr 0min

0 / 8 lessons complete

Ansible Galaxy

• 1hr 33min

0 / 6 lessons complete

Ansible Facts, Variables, Passwords and Templates

• 2hr 5min

0 / 9 lessons complete

Advanced Ansible Playbook Creation

• 1hr 52min

0 / 8 lessons complete

Course Conclusion

• 11min

0 / 1 lessons complete

Instructions

Q&A (0)

Notes (0)

Resources (0)

Saving Progress...

Resources

There are no resources for this lesson.

Notes can be saved and accessed anywhere in the course. They also double as bookmarks so you can quickly review important lesson material.

Create note

In this lesson, you'll learn how to install Ansible on your ansible-controller VM that you set up in the previous lessons. Additionally, if you are using a Linux-based host computer, the process to install Ansible directly on your host will be similar. By the end of this lesson, you'll have Ansible installed and ready for automation tasks.

Preparing for Installation

Before installing Ansible, make sure your system is up to date. Open a terminal on your Ansible Controller VM or your Linux host and run the following commands:

sudo apt update
sudo apt upgrade

Installing Ansible

  1. Add Ansible's Official PPA (Personal Package Archive): Ansible can be installed from its official PPA, which often contains the latest version compared to what might be in the default repositories. On your Ansible Controller VM or Linux host, add the PPA by typing:
sudo apt-add-repository ppa:ansible/ansible
  1. Update Your Package List: After adding the PPA, update your package list to include the newly added repository:
sudo apt update
  1. Install Ansible: Now, you can install Ansible with:
sudo apt install ansible

This command will install Ansible and any required dependencies.

  1. Verify the Installation: Once the installation is complete, you can verify it by checking the Ansible version:
ansible --version

This command should return the version of Ansible that was installed, confirming that the installation was successful as shown below:

ansible [core 2.15.8]
  config file = /etc/ansible/ansible.cfg
  configured module search path = ['/home/paulh/.ansible/plugins/modules', '/usr/share/ansible/plugins/modules']
  ansible python module location = /usr/lib/python3/dist-packages/ansible
  ansible collection location = /home/paulh/.ansible/collections:/usr/share/ansible/collections
  executable location = /usr/bin/ansible
  python version = 3.10.12 (main, Nov 20 2023, 15:14:05) [GCC 11.4.0] (/usr/bin/python3)
  jinja version = 3.0.3
  libyaml = True

Conclusion

You now have Ansible installed on your Ansible Controller VM, and possibly on your Linux host. With Ansible installed, you're ready to start exploring automation tasks and learning how to manage your IT infrastructure efficiently. In the upcoming lessons, we'll delve into Ansible's basic commands and start writing our first playbooks.

0 0 votes
Lesson Rating
Subscribe
Notify of
profile avatar
0 Comments
Inline Feedbacks
View all comments