Scaffold a Role with ansible-galaxy init
Generate the standard role skeleton.
Do Not Build It By Hand
You could create every role folder manually, but Ansible gives you a command that scaffolds the whole structure in one step.
ansible-galaxy init
The ansible-galaxy init command generates a complete, ready-to-fill role skeleton with all the standard directories.
ansible-galaxy init nginxAll lessons in this course
- Why Roles: From Monolith to Modules
- The Role Directory Anatomy
- Scaffold a Role with ansible-galaxy init
- Apply Roles & Pass Role Variables