Questions tagged [ansible-galaxy]

Use this tag for questions regarding Ansible Galaxy (a site for publishing and downloading the roles) and the `ansible-galaxy` command-line tool. For general questions regarding Ansible roles use tag:ansible-role

128 questions
159
votes
14 answers

How to automatically install Ansible Galaxy roles?

All my Ansible playbooks/roles are checked in to my git repo. However, for Ansible Galaxy roles I always have to explicitly download them one by one on every machine I want to run Ansible from. It's even tough to know in advance exactly which…
pdeva
  • 43,605
  • 46
  • 133
  • 171
136
votes
5 answers

Ansible Playbooks vs Roles

According to the Ansible docs, a Playbook is: ...the basis for a really simple configuration management and multi-machine deployment system, unlike any that already exist, and one that is very well suited to deploying complex applications. And,…
smeeb
  • 27,777
  • 57
  • 250
  • 447
56
votes
6 answers

Ansible Galaxy roles install in to a specific directory?

So I figured I should start using Ansible Galaxy when possible, instead of writing my own roles. I just installed my first role and it was installed to /etc/local/ansible/roles (I am on OSX). Now I wonder how you install this roles where I actually…
StenW
  • 1,964
  • 5
  • 24
  • 27
24
votes
5 answers

Ansible-galaxy throws ImportError: No module named yaml

When I try to install ansible role, I see this exception. $ ansible-galaxy install zzet.postgresql Traceback (most recent call last): File "/Users/myHomeDir/.homebrew/Cellar/ansible/1.4.3/libexec/bin/ansible-galaxy", line 34, in import…
Alexander Vagin
  • 575
  • 1
  • 8
  • 15
18
votes
1 answer

Ansible roles/packages - Ansible Galaxy - error on installation MAC OSX

Im trying to install ansible-galaxy roles on Mac OS X El Capitan via CLI $ ansible-galaxy install -r requirements.yml I am getting this error: ERROR! Unexpected Exception: (setuptools 1.1.6…
15
votes
2 answers

Install Ansible collections directly from a git URI with ansible-galaxy

The documentation for ansible-galaxy indicates the following: The ansible-galaxy command comes bundled with Ansible, and you can use it to install roles from Galaxy or directly from a git based SCM. You can also use it to create a new role, remove…
user189198
15
votes
2 answers

Using credentials for ansible-galaxy with private gitlab repo in a Jenkins Job

I have a set of roles that I need to install with ansible-galaxy. - src: 'https://gitlab.private/role-openstack-net.git' scm: 'git' version: '1.0.0' name: 'role-openstack-net' - src: 'https://gitlab.private/role-openstack-subnet.git' scm:…
Juliatzin
  • 18,455
  • 40
  • 166
  • 325
13
votes
3 answers

ansible-galaxy role fails with "do not have permission to modify /etc/ansible/roles/"

tl;dr = How do OS X users recommend working around this permissions error? I'm on OS X 10.10.1 and I recently installed Ansible running the following: sudo pip install ansible --quiet sudo pip install ansible --upgrade I want to start off with a…
mbb
  • 3,052
  • 1
  • 27
  • 28
12
votes
6 answers

How to fix following ansible galaxy SSL error?

Started learning Ansible and want to facilitate ansible-galaxy search nginx command, but I'm getting: ERROR! Unknown error when attempting to call Galaxy at 'https://galaxy.ansible.com/api/api':
Maciej
  • 1,209
  • 4
  • 16
  • 26
9
votes
1 answer

How to automatically install Ansible Galaxy roles, using Vagrant?

Using one playbook only, then it's not possible to have Ansible automagically install the dependent roles. At least according to this SO thread. But, I have the added "advantage" of using Vagrant and Vagrant's Ansible local provisioner. Any tricks I…
Martin Andersson
  • 18,072
  • 9
  • 87
  • 115
9
votes
6 answers

ansible-galaxy and git clone from Bitbucket.org

I am using ansible-galaxy (v2.0.0.2) to install ansible roles that which has the source code on Bitbucket through the requirements.yml file. But I could not checkout the code from bitbucket.org with the private key. Here is the error message, and…
ezlee
  • 429
  • 1
  • 5
  • 6
7
votes
1 answer

Updating a Ansible role which has been installed with ansible-galaxy from a GitHub repo

Whenever I change code in my Ansible role in a repository, I also want to have that code updated in the roles directory on my test machine. What I do to obtain the new code is to remove the role by running ansible-galaxy remove rolename install the…
Rob
  • 71
  • 1
  • 2
7
votes
3 answers

Is there a way to override a template defined into an ansible galaxy role?

I'm trying to set up a server with ansible and I'd like to use this galaxy role. It defines a template that I'd like to customize, but I don't know how. Right now I defined the role into requirements.yml and I installed it using: ansible-galaxy…
delphaber
  • 199
  • 1
  • 13
6
votes
2 answers

How to install ansible galaxy a collection's role dependencies?

I'm trying to use Ansible Galaxy collections and can't find a way how to install dependencies of roles inside a collection which I specified in a role's meta/main.yml dependencies list. As I understand a galaxy.yml of a collection can have only the…
6
votes
1 answer

How do I install ansible-galaxy on mac os using brew?

Is it possible to install ansible galaxy using brew on mac os? I tried: $ brew install ansible-galaxy Updating Homebrew... ==> Auto-updated Homebrew! Updated 3 taps (homebrew/cask-versions, homebrew/core and homebrew/cask). ==> Updated…
user674669
  • 10,681
  • 15
  • 72
  • 105
1
2 3
8 9