'\" t .\" Title: ansible-galaxy .\" Author: [see the "AUTHOR" section] .\" Generator: DocBook XSL Stylesheets v1.78.1 .\" Date: 01/16/2017 .\" Manual: System administration commands .\" Source: Ansible 2.2.1.0 .\" Language: English .\" .TH "ANSIBLE\-GALAXY" "1" "01/16/2017" "Ansible 2\&.2\&.1\&.0" "System administration commands" .\" ----------------------------------------------------------------- .\" * Define some portability stuff .\" ----------------------------------------------------------------- .\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ .\" http://bugs.debian.org/507673 .\" http://lists.gnu.org/archive/html/groff/2009-02/msg00013.html .\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ .ie \n(.g .ds Aq \(aq .el .ds Aq ' .\" ----------------------------------------------------------------- .\" * set default formatting .\" ----------------------------------------------------------------- .\" disable hyphenation .nh .\" disable justification (adjust text to left margin only) .ad l .\" ----------------------------------------------------------------- .\" * MAIN CONTENT STARTS HERE * .\" ----------------------------------------------------------------- .SH "NAME" ansible-galaxy \- manage roles using galaxy\&.ansible\&.com .SH "SYNOPSIS" .sp ansible\-galaxy [delete|import|info|init|install|list|login|remove|search|setup] [\-\-help] [options] \&... .SH "DESCRIPTION" .sp \fBAnsible Galaxy\fR is a shared repository for Ansible roles\&. The ansible\-galaxy command can be used to manage these roles, or for creating a skeleton framework for roles you\(cqd like to upload to Galaxy\&. .SH "COMMON OPTIONS" .PP \fB\-h\fR, \fB\-\-help\fR .RS 4 Show a help message related to the given sub\-command\&. .RE .SH "INSTALL" .sp The \fBinstall\fR sub\-command is used to install roles\&. .SS "USAGE" .sp $ ansible\-galaxy install [options] [\-r FILE | role_name(s)[,version] | tar_file(s)] .sp Roles can be installed in several different ways: .sp .RS 4 .ie n \{\ \h'-04'\(bu\h'+03'\c .\} .el \{\ .sp -1 .IP \(bu 2.3 .\} A username\&.rolename[,version] \- this will install a single role\&. The Galaxy API will be contacted to provide the information about the role, and the corresponding \&.tar\&.gz will be downloaded from \fBgithub\&.com\fR\&. If the version is omitted, the most recent version available will be installed\&. .RE .sp .RS 4 .ie n \{\ \h'-04'\(bu\h'+03'\c .\} .el \{\ .sp -1 .IP \(bu 2.3 .\} A file name, using \fB\-r\fR \- this will install multiple roles listed one per line\&. The format of each line is the same as above: username\&.rolename[,version] .RE .sp .RS 4 .ie n \{\ \h'-04'\(bu\h'+03'\c .\} .el \{\ .sp -1 .IP \(bu 2.3 .\} A \&.tar\&.gz of a valid role you\(cqve downloaded directly from \fBgithub\&.com\fR\&. This is mainly useful when the system running Ansible does not have access to the Galaxy API, for instance when behind a firewall or proxy\&. .RE .SS "OPTIONS" .PP \fB\-f\fR, \fB\-\-force\fR .RS 4 Force overwriting an existing role\&. .RE .PP \fB\-i\fR, \fB\-\-ignore\-errors\fR .RS 4 Ignore errors and continue with the next specified role\&. .RE .PP \fB\-n\fR, \fB\-\-no\-deps\fR .RS 4 Don\(cqt download roles listed as dependencies\&. .RE .PP \fB\-p\fR \fIROLES_PATH\fR, \fB\-\-roles\-path=\fR\fIROLES_PATH\fR .RS 4 The path to the directory containing your roles\&. The default is the \fBroles_path\fR configured in your \fBansible\&.cfg\fR file (/etc/ansible/roles if not configured) .RE .PP \fB\-r\fR \fIROLE_FILE\fR, \fB\-\-role\-file=\fR\fIROLE_FILE\fR .RS 4 A file containing a list of roles to be imported, as specified above\&. This option cannot be used if a rolename or \&.tar\&.gz have been specified\&. .RE .SH "REMOVE" .sp The \fBremove\fR sub\-command is used to remove one or more roles\&. .SS "USAGE" .sp $ ansible\-galaxy remove role1 role2 \&... .SS "OPTIONS" .PP \fB\-p\fR \fIROLES_PATH\fR, \fB\-\-roles\-path=\fR\fIROLES_PATH\fR .RS 4 The path to the directory containing your roles\&. The default is the \fBroles_path\fR configured in your \fBansible\&.cfg\fR file (/etc/ansible/roles if not configured) .RE .SH "INIT" .sp The \fBinit\fR command is used to create an empty role suitable for uploading to https://galaxy\&.ansible\&.com (or for roles in general)\&. .SS "USAGE" .sp $ ansible\-galaxy init [options] role_name .SS "OPTIONS" .PP \fB\-f\fR, \fB\-\-force\fR .RS 4 Force overwriting an existing role\&. .RE .PP \fB\-p\fR \fIINIT_PATH\fR, \fB\-\-init\-path=\fR\fIINIT_PATH\fR .RS 4 The path in which the skeleton role will be created\&.The default is the current working directory\&. .RE .PP \fB\-\-offline\fR .RS 4 Don\(cqt query the galaxy API when creating roles .RE .SH "LIST" .sp The \fBlist\fR sub\-command is used to show what roles are currently installed\&. You can specify a role name, and if installed only that role will be shown\&. .SS "USAGE" .sp $ ansible\-galaxy list [role_name] .SS "OPTIONS" .PP \fB\-p\fR \fIROLES_PATH\fR, \fB\-\-roles\-path=\fR\fIROLES_PATH\fR .RS 4 The path to the directory containing your roles\&. The default is the \fBroles_path\fR configured in your \fBansible\&.cfg\fR file (/etc/ansible/roles if not configured) .RE .SH "SEARCH" .sp The \fBsearch\fR sub\-command returns a filtered list of roles found on the remote server\&. .SS "USAGE" .sp $ ansible\-galaxy search [options] [searchterm1 searchterm2] .SS "OPTIONS" .PP \fB\-\-galaxy\-tags\fR .RS 4 Provide a comma separated list of Galaxy Tags on which to filter\&. .RE .PP \fB\-\-platforms\fR .RS 4 Provide a comma separated list of Platforms on which to filter\&. .RE .PP \fB\-\-author\fR .RS 4 Specify the username of a Galaxy contributor on which to filter\&. .RE .PP \fB\-c\fR, \fB\-\-ignore\-certs\fR .RS 4 Ignore TLS certificate errors\&. .RE .PP \fB\-s\fR, \fB\-\-server\fR .RS 4 Override the default server https://galaxy\&.ansible\&.com\&. .RE .SH "INFO" .sp The \fBinfo\fR sub\-command shows detailed information for a specific role\&. Details returned about the role included information from the local copy as well as information from galaxy\&.ansible\&.com\&. .SS "USAGE" .sp $ ansible\-galaxy info [options] role_name[, version] .SS "OPTIONS" .PP \fB\-p\fR \fIROLES_PATH\fR, \fB\-\-roles\-path=\fR\fIROLES_PATH\fR .RS 4 The path to the directory containing your roles\&. The default is the \fBroles_path\fR configured in your \fBansible\&.cfg\fR file (/etc/ansible/roles if not configured) .RE .PP \fB\-c\fR, \fB\-\-ignore\-certs\fR .RS 4 Ignore TLS certificate errors\&. .RE .PP \fB\-s\fR, \fB\-\-server\fR .RS 4 Override the default server https://galaxy\&.ansible\&.com\&. .RE .SH "LOGIN" .sp The \fBlogin\fR sub\-command is used to authenticate with galaxy\&.ansible\&.com\&. Authentication is required to use the import, delete and setup commands\&. It will authenticate the user, retrieve a token from Galaxy, and store it in the user\(cqs home directory\&. .SS "USAGE" .sp $ ansible\-galaxy login [options] .sp The \fBlogin\fR sub\-command prompts for a \fBGitHub\fR username and password\&. It does NOT send your password to Galaxy\&. It actually authenticates with GitHub and creates a personal access token\&. It then sends the personal access token to Galaxy, which in turn verifies that you are you and returns a Galaxy access token\&. After authentication completes the \fBGitHub\fR personal access token is destroyed\&. .sp If you do not wish to use your GitHub password, or if you have two\-factor authentication enabled with GitHub, use the \fB\-\-github\-token\fR option to pass a personal access token that you create\&. Log into GitHub, go to Settings and click on Personal Access Token to create a token\&. .SS "OPTIONS" .PP \fB\-c\fR, \fB\-\-ignore\-certs\fR .RS 4 Ignore TLS certificate errors\&. .RE .PP \fB\-s\fR, \fB\-\-server\fR .RS 4 Override the default server https://galaxy\&.ansible\&.com\&. .RE .PP \fB\-\-github\-token\fR .RS 4 Authenticate using a \fBGitHub\fR personal access token rather than a password\&. .RE .SH "IMPORT" .sp Import a role from \fBGitHub\fR to galaxy\&.ansible\&.com\&. Requires the user first authenticate with galaxy\&.ansible\&.com using the \fBlogin\fR subcommand\&. .SS "USAGE" .sp $ ansible\-galaxy import [options] github_user github_repo .SS "OPTIONS" .PP \fB\-c\fR, \fB\-\-ignore\-certs\fR .RS 4 Ignore TLS certificate errors\&. .RE .PP \fB\-s\fR, \fB\-\-server\fR .RS 4 Override the default server https://galaxy\&.ansible\&.com\&. .RE .PP \fB\-\-branch\fR .RS 4 Provide a specific branch to import\&. When a branch is not specified the branch found in meta/main\&.yml is used\&. If no branch is specified in meta/main\&.yml, the repo\(cqs default branch (usually master) is used\&. .RE .SH "DELETE" .sp The \fBdelete\fR sub\-command will delete a role from galaxy\&.ansible\&.com\&. Requires the user first authenticate with galaxy\&.ansible\&.com using the \fBlogin\fR subcommand\&. .SS "USAGE" .sp $ ansible\-galaxy delete [options] github_user github_repo .SS "OPTIONS" .PP \fB\-c\fR, \fB\-\-ignore\-certs\fR .RS 4 Ignore TLS certificate errors\&. .RE .PP \fB\-s\fR, \fB\-\-server\fR .RS 4 Override the default server https://galaxy\&.ansible\&.com\&. .RE .SH "SETUP" .sp The \fBsetup\fR sub\-command creates an integration point for \fBTravis CI\fR, enabling galaxy\&.ansible\&.com to receive notifications from \fBTravis\fR on build completion\&. Requires the user first authenticate with galaxy\&.ansible\&.com using the \fBlogin\fR subcommand\&. .SS "USAGE" .sp $ ansible\-galaxy setup [options] source github_user github_repo secret .sp .RS 4 .ie n \{\ \h'-04'\(bu\h'+03'\c .\} .el \{\ .sp -1 .IP \(bu 2.3 .\} Use \fBtravis\fR as the source value\&. In the future additional source values may be added\&. .RE .sp .RS 4 .ie n \{\ \h'-04'\(bu\h'+03'\c .\} .el \{\ .sp -1 .IP \(bu 2.3 .\} Provide your \fBTravis\fR user token as the secret\&. The token is not stored by galaxy\&.ansible\&.com\&. A hash is created using github_user, github_repo and your token\&. The hash value is what actually gets stored\&. .RE .SS "OPTIONS" .PP \fB\-c\fR, \fB\-\-ignore\-certs\fR .RS 4 Ignore TLS certificate errors\&. .RE .PP \fB\-s\fR, \fB\-\-server\fR .RS 4 Override the default server https://galaxy\&.ansible\&.com\&. .RE .PP \-\-list .RS 4 Show your configured integrations\&. Provides the ID of each integration which can be used with the remove option\&. .RE .PP \-\-remove .RS 4 Remove a specific integration\&. Provide the ID of the integration to be removed\&. .RE .SH "AUTHOR" .sp Ansible was originally written by Michael DeHaan\&. See the AUTHORS file for a complete list of contributors\&. .SH "COPYRIGHT" .sp Copyright \(co 2014, Michael DeHaan .sp Ansible is released under the terms of the GPLv3 License\&. .SH "SEE ALSO" .sp \fBansible\fR(1), \fBansible\-pull\fR(1), \fBansible\-doc\fR(1), \fBansible\-playbook\fR(1), \fBansible\-vault\fR(1) .sp Extensive documentation is available in the documentation site: http://docs\&.ansible\&.com\&. IRC and mailing list info can be found in file CONTRIBUTING\&.md, available in: https://github\&.com/ansible/ansible