Summary

A summary of the content covered in the chapter.

This chapter introduced inventories, groups, and Ansible vault.

Inventory

We started with introducing inventories, and the INI file as an inventory source. You learned how to create your first inventory and store group and host variables in it.

Groups

We further introduced groups to keep our inventory clean and better organize the infrastructure. You learned how you could target different hosts based on the groups.

You organized the host and group variables in sub-directories to keep your inventory clean as the number of variables grows. The following subdirectories were introduced:

  • group_vars
  • host_vars

Ansible Vault

Lastly, we introduced Ansible vault to keep your secrets secure. You learned two methods to secure your secrets with Ansible Vault:

  • using encrypted files
  • using encrypted strings

You practiced the following options with the ansible-vault command:

Using encrypted files

  • encrypt
  • edit
  • view
  • decrypt

Using encrypted strings

  • encrypt_string
  • debug

Delete the environments

In case you are going to visit the rest of the course later, you can delete the infrastructure to avoid any unexpected bills.

Disclaimer: Run the playbook at your own risk!
It is highly recommended you use a development AWS account and Azure subscription before executing these playbooks.

You can review the playbooks in the sections for Deploy to Azure and Deploy to AWS to delete the infrastructure.

Get hands-on with 1200+ tech skills courses.