I just initialize ansible project and not sure which approach is better to create ansible roles. Should I create one usecase per roles. Or it is better to create multiple usecase inside one roles.
For example, I have this multiple roles which represent each usecase (install, add_client) in same context (VPN).
- roles
- vpn_install
- tasks
- main.yml
- vpn_add_client
- tasks
- main.yml
or I have this role directory which contains multiple usercase (install, add client) and will be imported in main.yml. and each usecase will be seperated by tags. So I can run it individually by only specifying the tags.
- roles
- vpn
- tasks
- main.yml
- installation
- install.yml
- add_vpn_client
- add-vpn-client.yml
Which one is better for long term project (project size will be increasing overtime) or which one is most common to be used?