Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Ansible -- Roles should be separated #4

Open
AdamHebby opened this issue Feb 28, 2021 · 0 comments
Open

Ansible -- Roles should be separated #4

AdamHebby opened this issue Feb 28, 2021 · 0 comments

Comments

@AdamHebby
Copy link
Contributor

Currently there isn't many Ansible roles so it won't take long to get in the habit of it now, rather than later.

The current rules in ansible/roles should be moved to public repos and installed via ansible-galaxy such as ansible-galaxy install -r requirements.yml -p roles/. That directory would then be gitignored

It means any contributors can work on roles themselves, without getting bogged down in the entire repo. It also means you can have testing on each role individually using molecule.

The primary purpose of this is if you install external roles, there is absolutely no point having your own copy which can be outdated easily. If you want to keep the two separate, you can make an external_roles folder but this requires a custom Ansible config file.

You can disregard this if you intend to never install an external role

The requirements.yml file would look like this:

- src: https://github.com/glimesh/ansible-role-glimesh-web
  version: v1.0.0
  name: glimesh-web
- src: https://github.com/glimesh/ansible-role-janus-ftl-nginx-ssl
  version: v1.0.0
  name: glimesh-web
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant