-
Notifications
You must be signed in to change notification settings - Fork 18
Role Naming Conventions
A traditional Ansible role is contained in a repository with a meta/main.yml
file in the project root. When installing a role from a traditional role, the Galaxy CLI will use the following rules to set the role name on the target file system:
Use galaxy_info.role_name, if set inmeta/main.yml
.When galaxy_info.role_name is not set, then start with the SCM repository name, and remove /^ansible-role[-+.]/, remove /^ansible[-+.]/, and remove /^role[-_+.]/
A multi-content repository does not contain a meta/main.yml
file at the root level, and may contain different Ansible content types, including one or more Ansible roles. When installing a role from such a repository, the Galaxy CLI will use the following rules to set the role name on the target file system:
Use galaxy_info.role_name, if set inrole_directory_name/meta/main.yml
When galaxy_info.role_name is not set, then start with the role's directory name , and remove /^ansible-role[-+.]/, remove /^ansible[-+.]/, and remove /^role[-_+.]/
When installing content from a Galaxy resource, the Galaxy CLI will verify the content exists on the Galaxy server, and install it using the namespace name, repository name, and content name specified on the command line. Consequently, the values specified on the command line will match the values returned by the API.
It will not attempt to modify the content name by removing ansible-role-
, nor ansible-
from the repository name, nor from any installed role names.
When installing content from an SCM+URL resource, the Galaxy CLI will use the SCM namespace, the repository name, and the content name found in the archive. The Galaxy CLI will either parse the URL, or interrogate the contents of the repository archive to determine the namespace and repository name values.
It will not attempt to locate the content on the Galaxy server. It will also not attempt to remove 'ansible-role', or ansible-' from the repository name, or from any installed role names.
- Home
- Using mazer and ansible
- Plans, designs, specs, use cases
- Making a release of mazer