[ansible-project] Attach/Remove IAM role

2017-12-27 Thread colin byrne
Is there a way to attach or remove an IAM role from an existing EC2 instance at present? If not, would there be interest in having this role? I'd be willing to make it if so. Thanks for any insights. -- You received this message because you are subscribed to the Google Groups "Ansible Proje

[ansible-project] mysql_users SHOW VIEW permission not granted.

2017-12-15 Thread colin byrne
I am struggling to set the SHOW VIEW permission for a user on a DATABASE. I have tried with the following syntax, to no avail: mysql_user: name: "{{ } }" password: "{{ } }" priv: ".*:SELECT,SHOW VIEW" host: "{{ }}" I am not sure what else to try! Thanks in advance

[ansible-project] Prevent outdated roles/plays from running

2017-10-04 Thread colin byrne
So now that we have a small team working on Ansible at our company, situations have arisen on multiple occasions where a change gets merged to master, run on all the servers, and then someone has a not-up-to-date branch locally and runs the outdated role/play on a some server, overwriting the c

[ansible-project] Dynamic Inventory to private VPC instances

2016-12-20 Thread colin byrne
I asked this a while back and I did not find a good solution back then... Hopefully something has changed! I am running Ansible outside of multiple VPCs, and have a set of configs in my ~/.ssh/config that get picked up when using a static inventory file. Is there a way to utilize that config w

[ansible-project] Re: Cannot generate diff with shell module

2016-11-30 Thread colin byrne
rpreting these as something you > don't want. > > Maybe. Give it a shot. :) > > On Wednesday, November 30, 2016 at 5:08:35 PM UTC-6, colin byrne wrote: >> >> I am trying to use the shell module to generate a diff between two remote >> files, but it is erring out

[ansible-project] Cannot generate diff with shell module

2016-11-30 Thread colin byrne
I am trying to use the shell module to generate a diff between two remote files, but it is erring out without giving me a warning or error: - name: create diff of old settings file and new settings file shell: diff /home/deploy/{{ application_name }}/shared/config/settings.yml /home/deploy/{{

[ansible-project] ec2_vpc module not idempotent

2016-10-18 Thread colin byrne
this module does not seem to be idempotent. Here is the documentation: http://docs.ansible.com/ansible/ec2_vpc_module.html, which seems to indicate that VPC's will NOT be created if a VPC already exists with equivalent resource_tags and cidr_block values. Unfortunately, as many times as I run

[ansible-project] Use ec2_remote_facts in another playbook

2016-02-23 Thread Colin Byrne
So the ec2_remote_facts has been great at getting the facts, but because it has to run against localhost, I have to run it as a separate play and can't use the registered information in a play run against other hosts. How can I transfer that registered variable to the new play/different hosts? T

[ansible-project] Re: get ec2 instance id after ec2 creation

2016-02-19 Thread Colin Byrne
I just confirmed that having only a private ip is NOT the reason for the failure here. I haven't yet tested wether being under a vpc subnet is the reason, which I would doubt... On Thursday, February 18, 2016 at 4:05:24 PM UTC-8, Colin Byrne wrote: > > Hey, so I feel like I am follow

[ansible-project] Re: get ec2 instance id after ec2 creation

2016-02-19 Thread Colin Byrne
"key_name": "ansible_provisioning", "launch_time": "2016-02-03T22:47:37.000Z", "placement": "us-west-1a", "private_dns_name": "ip-10-101-

[ansible-project] get ec2 instance id after ec2 creation

2016-02-18 Thread Colin Byrne
Hey, so I feel like I am following all the tutorials but I can't seem to get the instance id after I create and instance with the ec2 module, to use for other modules, like the ec2_vol module, which depends on the ec2 instance id to attach it to the correct instance. I am not sure if I am m

[ansible-project] Re: Evaluate variable immediately, save for later

2016-02-02 Thread Colin Byrne
Thanks! For some reason I was stuck on using exclusively handlers or registered variables. Using them in combination is definitely the way to go. -C On Monday, February 1, 2016 at 7:04:25 PM UTC-8, Colin Byrne wrote: > > Hey, so I have the following sequence where I first register a va

[ansible-project] Evaluate variable immediately, save for later

2016-02-01 Thread Colin Byrne
Hey, so I have the following sequence where I first register a variable, then want to evaluate stats from it later but I want the stats from when the variable was first created. What is the best way to do this? I could see registering a second variable immedeatly that evaulates properties of t

[ansible-project] gather tag name about instance

2016-01-29 Thread Colin Byrne
Hey, So I want to access the tag name I set at initial ec2 creation to use it as my hostname throughout the server. To set the tag_name, I use a dictionary / sub_list as such: server_group_settings: integ: security_groups: ['sg-81398ee4', 'sg-a6398ec3'] image: ami-06116566 insta

Re: [ansible-project] AWS VPC inventory no public

2016-01-12 Thread Colin Byrne
ipt and minor configs required if you'd > like. > > -MItch​ > > On Tue, Jan 12, 2016 at 12:37 PM, Colin Byrne > wrote: > >> Hey, >> >> So I would love to get the aws ec2 inventory working, but I cant seem to >> find a way to connec

[ansible-project] AWS VPC inventory no public

2016-01-12 Thread Colin Byrne
Hey, So I would love to get the aws ec2 inventory working, but I cant seem to find a way to connect to my instances within a VPC subnet. I changed the ec2.ini configuration to: destination_variable = private_dns_name so that now the command 'ec2.py --list' now finds the instances, but I sti

Re: [ansible-project] concatenate variables and strings in file lookup

2016-01-07 Thread Colin Byrne
role_path + > '/files/public_keys/' + item.1) }}" > > On Thu, Jan 7, 2016 at 3:16 PM, Colin Byrne > wrote: > > Hey so I have a list of developer names in a dictionary and I am trying > to > > do a file lookup on their ssh key, > > > > I

[ansible-project] Re: nesting dictionary vars in vars

2016-01-04 Thread Colin Byrne
; On Tuesday, December 29, 2015 at 6:01:40 PM UTC-6, Colin Byrne wrote: >> >> Hey so I am trying to loop through a dictionary list of servers I want to >> create, and want to evaluate some variables based on the iteration I am on. >> I am not sure if I has a syntax error or

[ansible-project] nesting dictionary vars in vars

2015-12-29 Thread Colin Byrne
Hey so I am trying to loop through a dictionary list of servers I want to create, and want to evaluate some variables based on the iteration I am on. I am not sure if I has a syntax error or I am trying something not supported by ansible, or if it's caused by the dictionary not being evaluated

[ansible-project] Re: Best way to Include Roles in tasks

2015-12-29 Thread Colin Byrne
> action: apt name={{item}} state=present update_cache=true > sudo: yes > with_items: > - libqtwebkit-dev > - node > - lots of other tasks > post_tasks: [] > > Regards, > Borys > > вторник, 29 декабря 2015 г., 2:08:37 UTC+2 пользователь Coli

[ansible-project] Best way to Include Roles in tasks

2015-12-28 Thread Colin Byrne
So I used to have one fairly long main.yml playbook that was used to perform a number of similar-tasks, one of which was to install rbenv, the ruby management tool. --- - name: create group titled deploy group: name=deploy state=present - name: update apt-cache sudo: yes apt

[ansible-project] Understanding var file placements and autoloads

2015-12-22 Thread Colin Byrne
I have two questions regarding variable behavior, given my file structure My file structure is like so: /roles /common /provision_ec2 /vars /main.yml /developer_list.yml /tasks /main.yml /group_vars /all /settings.yml /production First: Why does a tas

[ansible-project] Re: Pass vault variables into large config vault file.

2015-12-18 Thread Colin Byrne
But can you encrypt the template somehow? -- You received this message because you are subscribed to the Google Groups "Ansible Project" group. To unsubscribe from this group and stop receiving emails from it, send an email to ansible-project+unsubscr...@googlegroups.com. To post to this group,

[ansible-project] Pass vault variables into large config vault file.

2015-12-17 Thread Colin Byrne
Hey, So I have a large config file that needs to be encrypted when pushed to a private repository. There are multiple server groups which it would be pushed too, so ideally I would be able to pass vars in to it, depending on the group. These vars would have to be encrypted as well. I feel

[ansible-project] Passing variables into files for syncing

2015-12-17 Thread Colin Byrne
Hey, so I have a number of essentially identical development servers which have a set of mostly-identical config files. In the config files are small configuration differences for each server, usually a differing API key or a differing host name, which will need to persist for the life of the fi

Re: [ansible-project] Concatenated Commands Not Executing

2015-12-16 Thread Colin Byrne
Thanks! worked great. On Wednesday, December 16, 2015 at 1:25:58 PM UTC-8, Brian Coca wrote: > > Use shell module instead > -- You received this message because you are subscribed to the Google Groups "Ansible Project" group. To unsubscribe from this group and stop receiving emails from it, se

[ansible-project] Concatenated Commands Not Executing

2015-12-16 Thread Colin Byrne
Hey so I am still getting familiar with Ansible so apologies if this is amateur stuff: I have an array of servers which I need to execute a series of commands on. I enter: ansible all -m command -a "sudo apt-get -y update && sudo apt-get -y dist-upgrade && sudo apt-get -y autoclean && sudo apt

[ansible-project] Can't ping remote server(s) from non-root user

2015-12-14 Thread Colin Byrne
Hey, So I am just getting started with Ansible, and have been able to ping a remote server with root access, but I am having trouble doing the same without root access. Running with verbose output I get: ansible all --check -m ping - -i /usr/local/bin/ansible_comp/hosts_next_version ES