[ansible-project] AWS trigger Ansible playbook run

2014-08-18 Thread Frank
plus another one more specific to this server. I thought that based on some sort of ‘autoscaling group variable’ I could figure what role to apply. Did someone already had this question waving in his mind? :) Thanks in advance, Frank  --  Change is the essential process of all existence

[ansible-project] last task

2014-08-21 Thread Frank
irst role) :) Cheers, Frank --  Change is the essential process of all existence. -- Spock, "Let That Be Your Last Battlefield", stardate 5730.2 -- You received this message because you are subscribed to the Google Groups "Ansible Project" group. To unsubscribe from this g

[ansible-project] creating users

2014-09-16 Thread Frank
FATAL: all hosts have already failed — aborting …” The question is: Is this layout the best approach for managing users/groups and keys? Cheers, Frank -- You received this message because you are subscribed to the Google Groups "Ansible Project" group. To unsubscribe from this group

[ansible-project] Re: creating users

2014-09-16 Thread Frank
Err, group is a reserved word… I’ve changed to mygroups: changed: [support] => (item={'key': 'admins', 'value': {'state': 'present'}}) changed: [support] => (item={'key': 'webmasters', 'value': {'state&#

Re: [ansible-project] Re: creating users

2014-09-16 Thread Frank
x27;d simplify by keeping a seperate list of users you want to be present and users to remove, that way you don't have to repeat all the 'state' stuff. Just make a task to add and another to remove. On Tue, Sep 16, 2014 at 10:03 AM, Frank wrote: Err, group is a reserved word… I’ve

[ansible-project] authorized_keys

2014-09-16 Thread Frank
": true, "item": [{"groups": ["admins", "webmasters"], "name": “user1"}, “user1.pub"]} msg: invalid key specified: BEGIN SSH2 PUBLIC KEY —— the keys are working fine. any tip? Regards, Frank -- You received this message beca

[ansible-project] Re: authorized_keys

2014-09-16 Thread Frank
err this key _was_ broken… fixed. --  Change is the essential process of all existence. -- Spock, "Let That Be Your Last Battlefield", stardate 5730.2 On 16 Sep 2014 at 16:43:39, Frank (urealfr...@gmail.com) wrote: Hi, I’m using authorized_keys module without success… users:   - n

[ansible-project] tower up and running

2014-09-18 Thread Frank
19:44 job_status drwxr-x---. 2 awx awx  4096 Sep 18 12:23 projects drwxr-xr-x. 3 awx awx  4096 Sep 18 12:23 public -rw-r--r--. 1 awx awx    33 Sep  8 19:39 wsgi.py -rw-r--r--. 2 awx awx   167 Sep  8 19:44 wsgi.pyc -rw-r--r--. 2 awx awx   167 Sep  8 19:44 wsgi.pyo Tips are welcome :) cheers, Fran

Re: [ansible-project] tower up and running

2014-09-18 Thread Frank
On 18 Sep 2014 at 16:24:19, Bill Nottingham (nott...@ansible.com) wrote: Frank (urealfr...@gmail.com) said:  > Hi guys,  >  > Finally I had time to install and setup Tower.  >  > After 10mins I had it up and running.  > I am following the PDF and everything went fine unti

[ansible-project] Create different users on different hosts

2017-07-13 Thread Frank
t file through which ansible is looping in alphabetical order. If I would rename the file "dep1" to "ZZZdep1" this would be the last file, and user "dep1" would be created. I can't find a way to achieve this, any help appreciated. Cheers, Frank -- You receive

[ansible-project] Question: how to use variable in with_sequence, casting to int results in zero value

2016-12-01 Thread frank
I am trying to process the result from the find module. The result contains 3 file paths which i would like to process in a loop. The number of files depends on the number of files found in the directories and is set by result.matched Using the with_sequence loop should do the trick, i think.

[ansible-project] with_items and register in a role/main.yml

2016-12-01 Thread frank
r is avariable after registering. So i think you sgould use "{{ r }}" -- 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...@googlegroup

Re: [ansible-project] Question: how to use variable in with_sequence, casting to int results in zero value

2016-12-08 Thread frank
Hi Kai, Thanks for your reaction. I think item.path won't work because of the structure of result.files. result.files contains a list [..path..], [.path..] ,So in the debug var i should reference item[0].path , item[1].path I worked my way around creating a list # create a list of policies

[ansible-project] Re: tomcat service to start only after the Redis replication is completed

2014-09-01 Thread Frank Steffen
Hi Nicolas, have you tried "wait_for"? Something like: wait_for: path=/var/log/redis.log search_regex="Finished with success" state =present Regards, Frank Am Montag, 1. September 2014 13:00:15 UTC+2 schrieb Nicolas G: > > Hi, > > We use a single redis ma

[ansible-project] Re: tomcat service to start only after the Redis replication is completed

2014-09-03 Thread Frank Steffen
You may delete or rotate the log file before. Am Dienstag, 2. September 2014 12:46:34 UTC+2 schrieb Nicolas G: > > Hi Frank, thanks for the reply. > > I was not aware of the search_regex thanks you, should be useful in other > cases but I don't thin in my case. The reason is

[ansible-project] host variables

2014-10-17 Thread Frank Soyer
the # ("12\#3456") to have it to work. Seems to return the right password without the "\". I know that I could check all this password to escape the #, but I'm so lazy, and as the string is quoted, it looks like a bug, isn't it ? Other characters like "$

[ansible-project] reffering variables inside vars.yml

2013-11-28 Thread ureal frank
fine but, what about this: foo: bar: hello baz: {{ bar }} and call it under the play with {{ foo.baz }}. Is there a way to do this? I've tried this 4 ways but wihout success... http://pastie.org/8514924 help :) cheers, Frank -- You received this message because you are subscribed to

[ansible-project] Single host failes on ansible-playbook

2014-03-20 Thread Frank Schiebel
e other hosts. So i figure the problem ist something that is returned from the host while gathering information. But I have no idea how I can debug this further, any hint would be highly appreciated. Thank you, Frank -- The host not working is r110-ws16 Ansible-playbook gives me this:

[ansible-project] on/off playooks for lots of resources w/o repeating them (minimal redundancy)

2016-07-11 Thread Frank Thommen
o playbooks. How can we have two playbooks, one mounting the mounts, the other unmounting them w/o having to duplicate the whole list in both playbooks? I'm sure there is a way, I just dont seem to be able to find the appropriate documentation page. Any pointer is appreciated frank

Re: [ansible-project] Re: on/off playooks for lots of resources w/o repeating them (minimal redundancy)

2016-07-11 Thread Frank Thommen
Thanks a lot. I'll give these a try. frank On 07/11/2016 11:42 AM, 'J Hawkesworth' via Ansible Project wrote: I can think of a couple of ways - there are probably more One way would be by having both playbooks include a vars file which has the list of mounts in it: http://d

[ansible-project] Confused about windows passwords and working with ec2?

2015-09-08 Thread Frank Perks
Hi, I am unsure exactly how i am supposed to handle and work with windows passwords when working with EC2 and inventories. I know i can query the passwords by using ec2_win_password, however i am unsure exactly how i can use this value to set the ansible_ssh_pass. For that connection. For exam

Re: [ansible-project] Confused about windows passwords and working with ec2?

2015-09-09 Thread Frank Perks
I didn't realize you can specify the ansible connection on a per task level! That completely changes stuff! I will give this a shot! On Tuesday, September 8, 2015 at 4:51:48 PM UTC-4, Brian Coca wrote: > > have you tried this? > > - hosts: windows > gather_facts: false > tasks: > > -

[ansible-project] Can't use local_action in Windows playbook in devel?

2015-09-09 Thread Frank Perks
I am trying to reboot a windows server after installing .net + a bunch of dependencies. I have a super simple PS module to schedule a reboot. However afterwords i would like to wait for the WinRM connection to come back: - name: Configuring windows hosts: windows roles: - win_dotnet_46

Re: [ansible-project] Can't use local_action in Windows playbook in devel?

2015-09-09 Thread Frank Perks
This is running latest version of devel (i updated this morning). delegate_to / connnection: local does not seem to work. On Wednesday, September 9, 2015 at 8:45:47 AM UTC-4, Brian Coca wrote: > > What version of ansible? have you tried with connection: local or > delegate_to: localhost:? > >

Re: [ansible-project] Confused about windows passwords and working with ec2?

2015-09-09 Thread Frank Perks
IHV0js On Wednesday, September 9, 2015 at 7:30:25 AM UTC-4, Frank Perks wrote: > > I didn't realize you can specify the ansible connection on a per task > level! > > That completely changes stuff! > > I will give this a shot! > > On Tuesday, September 8, 2015

Re: [ansible-project] Can't use local_action in Windows playbook in devel?

2015-09-09 Thread Frank Perks
by simply defining another play with the wait_for winrm. Then starting another play for the remaining windows tasks. On Wednesday, September 9, 2015 at 10:29:05 AM UTC-4, Trond Hindenes wrote: > > Frank, I actually put a lot of work into the trondhindenes.win_reboot role > you can fin

Re: [ansible-project] Can't use local_action in Windows playbook in devel?

2015-09-09 Thread Frank Perks
Just to add something else, in 1.9.4 both Trond and my stuff works fine. On Wednesday, September 9, 2015 at 10:44:35 AM UTC-4, Frank Perks wrote: > > Hi Trond, > > I tried your module, and it fails with the same issue as above. > > fatal: [52.8.31.205]: FAILED! => {"fa

Re: [ansible-project] Can't use local_action in Windows playbook in devel?

2015-09-12 Thread Frank Perks
strange. I spent a lot of time making sure it would work in >> both 1.9 and 2.0. Will test and report back. >> >> On Wednesday, September 9, 2015 at 5:46:39 PM UTC+2, Frank Perks wrote: >>> >>> Just to add something else, in 1.9.4 both Trond and my stuff works fine

[ansible-project] wierd substitution at regex_replace filter

2015-09-14 Thread Frank Tamás
Hi, I need a list with the ip address of play_hosts. This template worked with 1.6.5, but it does not work with 1.9.3. I would appreciate any help, what could be wrong. --- - hosts: test vars: galera_cluster_members: "{{ play_hosts|map('regex_replace','(.*)', \"{{ hostvars['1']['ans

[ansible-project] Re: Setting hostname

2015-09-14 Thread Frank Perks
ansible-hostname is a role, and should be in the roles directory. Assuming /home/stefaansm/trusty64/Ansible/ is where your playbooks are. Then ansible-hostname should be located at /home/stefaansm/trusty64/Ansible/roles/ansible-hostname On Monday, September 14, 2015 at 8:20:06 AM UTC-4, Kuber

[ansible-project] Re: Required variables in var in inline vars

2015-09-14 Thread Frank Perks
You make an variable mandatory to throw an error if a var is not defined: - hosts: vars: var_required_by_role: - name: "{{ variable | mandatory }}" user: "foo" roles: - myrole Alternatively you can edit ansible.cfg to change this setting to True error_on_undefined_vars

[ansible-project] Re: Newbie question on ansible inventory?

2015-09-14 Thread Frank Perks
Hi, The easiest way imo is to define groups in your inventory. Group the servers that use the same war file togther, and then add a corresponding var file for that group in group_vars. In group vars define a list of the wars on that server. E.g.: qa01.yml war_files: - /something/app1.war

[ansible-project] Re: Setting hostname

2015-09-15 Thread Frank Perks
code uses hostname_fqdn instead. On Tuesday, September 15, 2015 at 1:41:52 AM UTC-4, Kuberboef wrote: > > > > On Monday, 14 September 2015 18:01:34 UTC+2, Frank Perks wrote: >> >> ansible-hostname is a role, and should be in the roles directory. >> >> Assuming /home/stefa

[ansible-project] Rescue block doesn't seem to work when error is in an included file

2015-09-15 Thread Frank Perks
So i was hoping to use blocks as an easy way to notify success/failure of ansible runs. - block: - include: build.yml - include: deploy_site.yml - name: Notify Slack it successfully deployed slack: - rescue: - name: Notify Slack it failed slack: When there is an error in ethe

[ansible-project] Re: Rescue block doesn't seem to work when error is in an included file

2015-09-15 Thread Frank Perks
I am dumb, and the issue is because i have: - rescue when it should be: rescue My mistake. On Tuesday, September 15, 2015 at 9:03:04 AM UTC-4, Frank Perks wrote: > > So i was hoping to use blocks as an easy way to notify success/failure of > ansible runs. > > - block

[ansible-project] Setting fact name dynamically in set_fact?

2015-09-21 Thread Frank Perks
I am trying to shrink ~30+ roles into a single role to drastically reduce the amount of duplicate and copy and pasted code into a single nice and neat role. One of the problems is each role sets a specifically named fact basically like: ec2__foo What i want to do is this: set_fact: "{{ som

[ansible-project] Re: Setting fact name dynamically in set_fact?

2015-09-22 Thread Frank Perks
Any ideas? This is really blocking me. On Monday, September 21, 2015 at 7:49:13 PM UTC-4, Frank Perks wrote: > > I am trying to shrink ~30+ roles into a single role to drastically reduce > the amount of duplicate and copy and pasted code into a single nice and > neat role. One of

[ansible-project] Re: Setting fact name dynamically in set_fact?

2015-09-25 Thread Frank Perks
t got a good example - so hope this > helps! and it may prompt some 'better' suggestions! ; ) > https://groups.google.com/d/msg/ansible-project/X1Q93QOk6Ew/ZygP5rXmfEkJ > > On Tuesday, September 22, 2015 at 12:49:13 AM UTC+1, Frank Perks wrote: >> >> I am trying to shri

Re: [ansible-project] Re: Setting fact name dynamically in set_fact?

2015-09-27 Thread Frank Perks
Thanks brian. action_plugins directory worked fine for me. :D On Friday, September 25, 2015 at 6:08:18 PM UTC-4, Brian Coca wrote: > > first, you should be able to just write the var into a facts file on > the target machine and fact gathering shoudl automatically pick it up > (http://docs.ansib

[ansible-project] Gathering ec2 instance facts with only a region and instance id?

2015-10-05 Thread Frank Perks
So i have a small problem, the only thing i have from the output of another tool is just an instance_id, along with its region. I need to grab some more information about the ec2 instance (such as the platform, tags, etc) in order to actually determine what inventory groups it belongs in. Unfo

Re: [ansible-project] Gathering ec2 instance facts with only a region and instance id?

2015-10-05 Thread Frank Perks
Thanks. Unfortunately it is not part of my dynamic inventory. Anisble runs a tool that provisions a bunch of ec2 instances, installs and configures a bunch of software on the systems (eventually this will be replaced by ansible i hope). The tool returns a series of instance ids and their regio

Re: [ansible-project] Gathering ec2 instance facts with only a region and instance id?

2015-10-06 Thread Frank Perks
, Frank Perks wrote: > > Thanks. Unfortunately it is not part of my dynamic inventory. > > Anisble runs a tool that provisions a bunch of ec2 instances, installs and > configures a bunch of software on the systems (eventually this will be > replaced by ansible i hope). The too

Re: [ansible-project] with_items: expects a list or a set by using it with when:

2015-11-05 Thread Frank Lye
I'm having the same issue. How can we make this task check if the variable exists before looping ? If we can't use when here, what can we do ? On Monday, October 20, 2014 at 5:02:25 PM UTC-4, Michael DeHaan wrote: > > The when is evaluated for each step in the loop, not before looping, which > i

[ansible-project] best location for async_status tasks in a playbook with multiple roles

2015-11-05 Thread Frank Ly
Say you have a playbook with multiple roles, for example: roles: - A - B - C in role A's or B's tasks/main.yml, there are a few tasks which are asynchronous fire and forget, do not poll tasks, for example: - name: do the thing (asynchronously) shell: Zhu Li do the thing args: creates

[ansible-project] Re: Use Ansible to discover/document an environment

2015-11-05 Thread Frank Ly
I've done something like this to create an inventory tracking spreadsheet. Haven't had the chance yet to improve it or convert it into a proper playbook. The setup module allows you to output facts to a tree structure with a JSON file for each host: $ ansible all -i inventory -u admin -m setu

[ansible-project] Re: execute shell script that starts background process

2015-11-05 Thread Frank Ly
Some resources for creating startup scripts: https://github.com/fhd/init-script-template https://github.com/jordansissel/pleaserun On Friday, December 12, 2014 at 8:33:27 AM UTC-5, Torsten Reinhard wrote: > > Hi, > > our development team delivers a start script for a "Listener process". > It loo

Re: [ansible-project] with_items: expects a list or a set by using it with when:

2015-11-08 Thread Frank Ly
Markus, That's exactly what I ended up doing. Thanks for your help. On Saturday, November 7, 2015 at 5:11:54 AM UTC-5, Markus Ellers wrote: > > you could put the tasks in a different yml file and do a conditional > include based on your "when". > -- You received this message because you are s

[ansible-project] Correct way to use fail module and negative conditionals

2015-12-19 Thread Frank Ly
I am trying to use the fail module at the very beginning of my playbook to check if the target server is a specific distribution and version. This way I can stop the playbook from running early on before any making any chances. playbook: --- - hosts: all tasks: - debug: msg='distro is {{

[ansible-project] Re: Correct way to use fail module and negative conditionals

2015-12-23 Thread Frank Ly
anyone able to help ? On Saturday, December 19, 2015 at 11:18:52 PM UTC-5, Frank Ly wrote: > > I am trying to use the fail module at the very beginning of my playbook to > check if the target server is a specific distribution and version. This way > I can stop the playbook from runn

[ansible-project] Re: Correct way to use fail module and negative conditionals

2016-01-05 Thread Frank Ly
server is running a supported distro fail: msg='Unsupported platform!' when: platform not in ["Ubuntu 14","CentOS 6"] That did the tricks! On Saturday, December 19, 2015 at 11:18:52 PM UTC-5, Frank Ly wrote: > > I am trying to use the fail module at th

[ansible-project] How to implement regular Ansible runs?

2016-01-20 Thread Frank Thommen
27;t even sure what keywords I should look for ;-) And no: Ansible Tower is not an option. We can't afford it. I appreciate any pointers Frank -- You received this message because you are subscribed to the Google Groups "Ansible Project" group. To unsubscribe from this group and sto

Re: [ansible-project] How to implement regular Ansible runs?

2016-01-20 Thread Frank Thommen
Thanks. Will have a look at ansible-pull. That seems to exactly do what we need. frank -- 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 ansib

[ansible-project] URI module equivalent for 'curl --upload-file'

2015-03-12 Thread Kyle Frank
HI. I've been trying to deploy a war file to the Tomcat manager using the uri module. I've been able to use curl from the command line to achieve this but I can't seem to translate it into an ansible task that uses the uri module. I could just use the shell module and insert the curl command

[ansible-project] Help on Ansible gcp_compute_snapshot module

2020-03-06 Thread FRANK L
"argument source_disk is of type and we were unable to convert to dict: cannot be converted to a dict"} " The more detailed Ansible gcp_compute_snapshot module can be found: https://docs.ansible.com/ansible/latest/modules/gcp_compute_snapshot_m

[ansible-project] Re: gcp_compute_* modules: trying to link using selfLink

2020-03-12 Thread Frank Gravato
Hi Lujaina, Were you able to get this working I'm currently working on a project trying to get this working exactly in the same setup as your post. On Thursday, January 2, 2020 at 9:46:16 AM UTC-5, Lujaina Abu Erban wrote: > > Thank you for the response, > But unfortunately, this also did not

[ansible-project] How to use host ranges with `ansible-playbook --limit`?

2018-01-03 Thread Frank Thommen
gnoring: host ERROR! Specified --limit does not match any hosts $ All hosts host010 - host027 are listed in the inventory. The same happens with double quotes and witout quotes around the limit pattern. How can I use host ranges witn --limit? Cheers frank -- You received this message becaus

Re: [ansible-project] How to use host ranges with `ansible-playbook --limit`?

2018-01-03 Thread Frank Thommen
On 04/01/18 07:11, Kai Stian Olstad wrote: On 03.01.2018 18:03, Frank Thommen wrote: I assumed, that host ranges could be used with ansible-playbook's --limit as they can be used in the inventory itself.  However this doesn't seem to be possible: It's called patterns http://d

[ansible-project] Tags not propagated to dynamically included tasks: Workaround?

2018-08-24 Thread Frank Thommen
ybooks and scalability. All things, that I appreciated with ansible so far. Cheers frank [*] i.e. we have e.g. the same tag "sysconfig" applied to an included taskfile for the role "common" and for the role "hw-server" and for the role "webserver",

Re: [ansible-project] Tags not propagated to dynamically included tasks: Workaround?

2018-08-24 Thread Frank Thommen
Thanks a lot Kai, On 08/24/2018 04:31 PM, Kai Stian Olstad wrote: On Friday, 24 August 2018 15.47.39 CEST Frank Thommen wrote: since "recently" (we realized just now), tags applied in role's main.yml task, like: /role/myrole/tasks/main.yml: - name: My Task include

[ansible-project] ios_config using before to set interface range on Cisco switch

2018-09-14 Thread Frank Clatterbaugh
When trying to use the before command to set an interface range on a Cisco switch it errors if I have more than one range. Both of these commands work fine from CLI. Example: Worksbefore: interface range twoGigabitEthernet 1/0/1-36 Doesn't work before: interface range twoGiga

[ansible-project] How to filter dictionary entries using Jinja

2017-04-26 Thread Frank Thommen
arget=". What I'd need is a syntax, which checks for each mount in the dictionary, if one of it's (possibly multiple) classes matches the (single) class of the server and then applies the mount. I could not find a usable Jinja-Syntax which I could use together with `when`. I

Re: [ansible-project] How to filter dictionary entries using Jinja

2017-04-28 Thread Frank Thommen
I haven't used roles yet. If a host can assume several roles, then this could work. Otherwise I'll have to deal with redundant dictionaries, which is exactly what I want to avoid. Thanks for the hint frank On 04/27/2017 09:17 AM, Dick Davies wrote: If each mount was managed

Re: [ansible-project] How to filter dictionary entries using Jinja

2017-04-28 Thread Frank Thommen
On 04/27/2017 12:40 PM, Kai Stian Olstad wrote: On 26.04.2017 16:20, Frank Thommen wrote: What I'd need is a syntax, which checks for each mount in the dictionary, if one of it's (possibly multiple) classes matches the (single) class of the server and then applies the mount. I could

[ansible-project] Can one add items to a list within(!) the inventory?

2017-06-16 Thread Frank Thommen
've tried several variants to no avail. users = users + ['user3'] users = [users, 'user3'] users = [{{users}}, 'user3'] Is such a lsit expansion possible? Cheers frank -- You received this message because you are subscribed to the Google Groups "

[ansible-project] Gathering facts in roles: Is it done multiple times?

2017-06-21 Thread Frank Thommen
ginning, but is this the case and/or how can I check this? frank -- 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...@goog

Re: [ansible-project] Gathering facts in roles: Is it done multiple times?

2017-06-21 Thread Frank Thommen
On 06/21/2017 11:01 AM, jean-y...@lenhof.eu.org wrote: Hi Frank, 21 juin 2017 10:29 "Frank Thommen" a écrit: Hi, from ansible's documentation I don't understand how ansible handles fact gathering when using roles: Are a host's facts gathered at each single playbo

[ansible-project] Looking for Ansible tower REST specifications (xml files)

2017-07-17 Thread frank vene
Frank -- 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, send email to ansib

[ansible-project] How to *not* print ansible diagnostic error messages?

2017-07-21 Thread Frank Thommen
: when: ES.rc == 1 Unfortunately when "./run.sh" fails, ansible prints a whole bunch of diagnostic output to the screen, which I am not interested in. How can I tell ansible *not* to print diagnostic error output of a specific step? We are running ansible 2.3.0 0 on CentOS 7 Ch

Re: [ansible-project] How to *not* print ansible diagnostic error messages?

2017-07-21 Thread Frank Thommen
Hi On 07/21/2017 05:17 PM, Branko Majic wrote: On Fri, 21 Jul 2017 16:34:53 +0200 Frank Thommen wrote: Hi, I have a playbook which executes a local task from which I need the exit status in later steps: - name: Get exit status of ./run.sh local_action: command ./run.sh

[ansible-project] What exactly is the "action" module and how does it work?

2017-07-27 Thread Frank Thommen
one, which is not documented yet? What exactly can one do with it? Cheers frank -- 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+

Re: [ansible-project] What exactly is the "action" module and how does it work?

2017-07-27 Thread Frank Thommen
Thanks a lot On 07/27/2017 07:25 PM, Kai Stian Olstad wrote: On 27. juli 2017 18:42, Frank Thommen wrote: Hi, I was looking for a way to run the distro-dependent package manager w/o too many "when"s and I found this (on https://ansible-tips-and-tricks.readthedocs.io/en/latest/os

[ansible-project] issues with task not working

2017-08-26 Thread Frank Dias
why does this not work? this is my play; - name: install PG HA hosts: dbs6 gather_facts: True any_errors_fatal: True vars: postgres_ha_cluster_master_host: dbs03.prodea-int.net postgres_ha_cluster_vip: 172.24.2.241 postgres_ha_pg_repl_pass: Pr0d3

[ansible-project] Re: issues with task not working

2017-08-27 Thread Frank Dias
role between OS version. currently our env is centos6 and plans are not set for when to go to centos7 as of yet On Saturday, August 26, 2017 at 9:50:42 PM UTC-5, Frank Dias wrote: > > why does this not work? > > this is my play; > - name: install PG HA > hosts: dbs6 &g

[ansible-project] help with variables

2017-09-27 Thread Frank Dias
Can I get your help in diagnosing why this is not working, I am getting the error on task #3 Here are the three tasks; I am wantng to key off of "stdout": "0", - name: Check if Redis Resources already exists shell: "pcs resource | grep '{{ item.key }}' | grep Master | wc -l"

[ansible-project] Re: help with variables

2017-09-27 Thread Frank Dias
I an trying to get set_fact: resource_{{ item.item.key }}={{item.stdout}} to be the output of "stdout": "0" meaning resource_{{ item.item.key }}= 0, later in other task I am checking if value is 0 or 1 On Wednesday, September 27, 2017 at 9:36:42 PM UTC-5, Frank Dias wrote

[ansible-project] How to specify the user home directory dynamatically with /home/{{ 'echo{$USER}' }}/sub_dir for copying files with Ansible copy module ?

2020-01-21 Thread FRANK L
amatically with /home/{{ 'echo{$USER}' }}/sub_dir for copying files with Ansible copy module ? Please help! Thanks in advance. Frank -- You received this message because you are subscribed to the Google Groups "Ansible Project" group. To unsubscribe from this group and

[ansible-project] Re: How to specify the user home directory dynamatically with /home/{{ 'echo{$USER}' }}/sub_dir for copying files with Ansible copy module ?

2020-01-22 Thread FRANK L
Hi Michael, Thanks for the tip. Yes, it works. Frank On Tuesday, January 21, 2020 at 9:07:45 PM UTC-5, FRANK L wrote: > > Hi, > > I would like to use git for managing Ansible playbooks for version control > on an admin server in GCP. So the idea is this: > each user

[ansible-project] Re: How to specify the user home directory dynamatically with /home/{{ 'echo{$USER}' }}/sub_dir for copying files with Ansible copy module ?

2020-01-22 Thread FRANK L
Dick, Thanks for the suggestion. We use visudo for editing the sudoers file in the first place. So if any mistakes made we could catch up in the first place. Your suggestion is the good one, and I like it. Frank On Tuesday, January 21, 2020 at 9:07:45 PM UTC-5, FRANK L wrote: > &

Re: [ansible-project] Get IP address, replace first three octets

2018-10-21 Thread Frank Thommen
u can do something like this - debug: msg="11.11.11.{{ ansible_default_ipv4.address.split('.').3 }}" sorry, dummy question: But where does the "split" come from? It's not a YAML statement, its not a standard Jinja2 filter and its not one of the special ansibl

Re: [ansible-project] Need help

2018-10-28 Thread Frank Thommen
ditionally you might consider to implement some inventory/monitoring which allows you to monitor software changes. Cheers frank On 28/10/18 17:34, Jonathan Lozada De La Matta wrote: I 2nd Michael's comment. On Sun, Oct 28, 2018 at 11:37 AM Michael Mullay <mailto:mmul...@gmail.com>>

Re: [ansible-project] Re: Copy multiple files to different locations on remote server

2018-11-02 Thread Frank Thommen
This is not the same: * copy module copies from the controller (where you run the ansible-playbook command) to the client * cp -f copies a file locally from client to itself frank On 11/02/2018 10:25 AM, Mohan L wrote: Try with command or shell module with cp -f. On Friday

Re: [ansible-project] Re: Copy multiple files to different locations on remote server

2018-11-02 Thread Frank Thommen
en you are using roles) and compare with remote file. frank On 11/02/2018 09:51 AM, Keshipeddy Anusha wrote: No change Mohan It is not replacing the file On Fri, Nov 2, 2018, 2:20 PM Mohan L <mailto:thefossg...@gmail.com> wrote: copy module with force yes automatically replace i

[ansible-project] "flush_handlers task does not support when conditional"...??

2018-11-29 Thread Frank Thommen
and I wonder a) why this - IMHO irritating - change of behaviour has been introduced and b) what would be the best way to work around it Any help or hint is appreciated. frank -- You received this message because you are subscribed to the Google Groups "Ansible Project" group. To uns

Re: [ansible-project] "flush_handlers task does not support when conditional"...??

2018-11-29 Thread Frank Thommen
allow this to work: https://github.com/ansible/ansible/issues/41313 On Thu, Nov 29, 2018 at 1:09 PM Frank Thommen <mailto:lists.ansi...@drosera.ch>> wrote: Hello, our latest yum update brought ansible from 2.4.2.0 to 2.7.2 and now we are facing     [WARNING]: flush_hand

[ansible-project] having issues with finding AMI

2018-12-06 Thread Frank Dias
ami_search_string: "amzn*amazon-ecs-optimized*" ec2_ami_find: name: "{{ ami_search_string }}" region: "{{ region }}" virtualization_type: hvm owner: aws-marketplace sort: creationDate sort_order: descending sort_end: 1 register: os_image when: - lc_ami is not

[ansible-project] Re: having issues with finding AMI

2018-12-06 Thread Frank Dias
uot;failed": true, "msg": "the field 'args' has an invalid value, which appears to include a variable that is undefined. The error was: list object has no element 0\n\nThe error appears to have been in '/var/lib/awx/projects/_1067__production_us/roles/aw

[ansible-project] Re: having issues with finding AMI

2018-12-06 Thread Frank Dias
here are the extra vars being set; account: prod ami_search_string: amzn-ami-2018.03.i-amazon-ecs-optimized asg_name: MiscServices cluster_name: MiscServices instance_type: m5.2xlarge lc_name: MiscServices region: us-west-2 On Thursday, December 6, 2018 at 2:45:21 PM UTC-6, Frank Dias wrote

Re: [ansible-project] Re: having issues with finding AMI

2018-12-11 Thread Frank Dias
ami-0307f7ccf6ea35750 refer to this link for the latest https://docs.aws.amazon.com/AmazonECS/latest/developerguide/ecs-optimized_AMI_launch_latest.html On Saturday, December 8, 2018 at 3:54:01 AM UTC-6, Karl Auer wrote: > > Hullo Frank. > > What specific AMI did you expect your

[ansible-project] ansible role/playbook cloudwatch alarm

2019-01-03 Thread Frank Dias
I am looking for a role or play book that one could run against AWS EC2 instances and set a cloud watch alarm for "cpucreditbalance". frank -- You received this message because you are subscribed to the Google Groups "Ansible Project" group. To unsubscribe from this grou

[ansible-project] mounting addition disks issue on new instance types

2019-02-14 Thread Frank Dias
the following play work on t2 instances, the issue I am running into is when I try to run it against a t3 instance it fails. it looks like the issue comes from the new instance types are using /dev/nvme0n1p1 for root and /nvme1n1 for the second drive. t2 vs (t3. m5 ,c5) so is there a ec2 fact th

[ansible-project] issues with tasks after upgrade

2019-02-20 Thread Frank Dias
Work task before upgrade: TASK [config-seeding : Clean build directory] ** Using module file /usr/lib/python2.7/site-packages/ansible/modules/files/file.py <127.0.0.1> ESTABLISH LOCAL CONNECTION FOR USER: awx <127.0.0.1> EXEC /bin/sh -c 'echo ~ && sleep 0' <127.0.

[ansible-project] playbooks failing after upgrade

2019-02-21 Thread Frank Dias
look at logs on playbooks that worked are now failing working task before upgrade TASK [config-seeding : Clean build directory] ** Using module file /usr/lib/python2.7/site-packages/ansible/modules/files/file.py <127.0.0.1> ESTABLISH LOCAL CONNECTION FOR USER: awx

[ansible-project] How to detect AWS instance type

2019-02-25 Thread Frank Dias
I have an old playbook that will add an addition volume and it works fine on t2 instances. With the move to t3 instances we also now have nvme based ebs. The play book uses lvm to setup the second volume we add the volume as xvdf so /dev/xvdf. Now on t3 instances when we add the volume as xvdf

[ansible-project] playbooks hang forever when client is swapping or has (NFS) mount problems

2016-08-19 Thread Frank Thommen
meout=10 -o ControlPath=/root/.ansible/cp/ansible-ssh-%h-%p-%r -tt buggyhost '/bin/sh -c '"'"'/usr/bin/python /root/.ansible/tmp/ansible-tmp-1471604358.1-265208088531534/setup.py; rm -rf "/root/.ansible/tmp/ansible-tmp-1471604358.1-265208088531534/" >

Re: [ansible-project] playbooks hang forever when client is swapping or has (NFS) mount problems

2016-08-19 Thread Frank Thommen
On 08/19/2016 01:54 PM, Jean-Yves LENHOF wrote: Le 19/08/2016 à 13:19, Frank Thommen a écrit : Dear all, doing my first steps with ansible I noticed, that on some clients executing playbooks completely hangs. The common problem on these hosts is, that they are either swapping (even very small

Re: [ansible-project] playbooks hang forever when client is swapping or has (NFS) mount problems

2016-08-19 Thread Frank Thommen
On 08/19/2016 02:33 PM, Jean-Yves LENHOF wrote: Le 19/08/2016 à 14:20, Frank Thommen a écrit : On 08/19/2016 01:54 PM, Jean-Yves LENHOF wrote: The first task ansible is doing is gathering facts In facts there are mounted filesystems, so the NFS one too [...] However I found this

[ansible-project] Module "include_vars" fails with when using "file" parameter

2016-08-23 Thread Frank Thommen
: FAILED! => {"failed": true, "msg": "Unexpected failure during module execution.", "stdout": ""} NO MORE HOSTS LEFT ***** to retry, use: --limit @testmyvars_2.retry PLAY

[ansible-project] Module "include_vars" fails with when using "file" parameter

2016-08-23 Thread Frank Thommen
ttributeError: 'NoneType' object has no attribute 'startswith' fatal: [MYHOST]: FAILED! => {"failed": true, "msg": "Unexpected failure during module execution.", "stdout": ""} NO MORE HOSTS LEFT ****

[ansible-project] Module "include_vars" fails with when using "file" parameter

2016-08-23 Thread Frank Thommen
ttribute 'startswith' fatal: [MYHOST]: FAILED! => {"failed": true, "msg": "Unexpected failure during module execution.", "stdout": ""} NO MORE HOSTS LEFT * to re

Re: [ansible-project] Module "include_vars" fails with when using "file" parameter

2016-08-24 Thread Frank Thommen
On 08/23/2016 03:38 PM, Frank Thommen wrote: Hi, when using the include_module with the "file" parameter, it fails with AttributeError: 'NoneType' object has no attribute 'startswith'. [...] Seems to have been fixed in the latest 2.2 release f. -- You

  1   2   >