Skip to content

Introducing Terragrunt native support! Get the full functionality of Terragrunt commands ๐Ÿš€๐Ÿš€

Find out more โ†’

Ansible Galaxyยป

If you followed previous examples in our Ansible documentation, you might have noticed that we do not do much in the Initialization phase.

Empty initialization phase

If it comes to Ansible stacks, during that phase we try to auto-detect the requirements.yml file that will be used to install dependencies. We will look for it in the following locations:

  • requirements.yml in the root directory
  • roles/requirements.yml for roles requirements
  • collections/requirements.yml for collections requirements

Tip

We also check for the alternative .yaml extension for the paths listed above.

As an example, try using an example requirements.yml file.

Example requirements.yml file
1
2
3
4
---
collections:
  - name: community.grafana
    version: 1.3.1

After our Initialization phase detects this file, it will use Ansible Galaxy to install those dependencies.

Installing community.grafana collection