[ansible-project] How can I execute one code block from local/master/control node?

2022-05-24 Thread bente...@gmail.com
I would like to execute the below tasks which create a user on a remote host and trigger an SMS gateway call from master/control node. This is running from awx/(tower) where I get some of the parameters through an AWX survey. - - name: create use

Re: [ansible-project] Control node environment & plugins

2022-05-24 Thread Gabriel Canton
I was kind of expecting something like that... It's a pity, but thanks a lot for clarifying this! El mar, 24 may 2022 a la(s) 10:58, Brian Coca (bc...@redhat.com) escribió: > no such facility exists, each task runs in a fork so even if you > change the environment successfully with a action plugi

[ansible-project] How to use copy with with_items and a 'sub list' (not sure if that is the right terminology)

2022-05-24 Thread morgan cox
Hi. Having an issue with a seemingly simple task, I just cannot work this out, pretty sure there is a simple way of doing this ... I have these example vars for a role acs_deploy_instances: - name: 'test1' config_dir: '/opt/www/test1' java_version: 'java-1.8.0-openjdk-headless

Re: [ansible-project] Issues with {{ ansible_hostname }} in task name within a role

2022-05-24 Thread Brian Coca
task names need to be the same across all hosts they are run on, so 'host scoped variables' are not valid for templating in the task names. https://github.com/ansible/ansible/issues/3103#issuecomment-18835432 -- -- Brian Coca -- You received this message because you are subscribed to th

Re: [ansible-project] multiple loops in single TASK

2022-05-24 Thread Brian Coca
You cannot have multiple loops per task (aside from already existing host loop) BUT you can basically get the same thing by making the data result into the same thing you would have in that case or you can loop over an include that has the task with it's own loop. -- -- Brian Coca --

Re: [ansible-project] Control node environment & plugins

2022-05-24 Thread Brian Coca
no such facility exists, each task runs in a fork so even if you change the environment successfully with a action plugin, it would not persist for the next task. -- -- Brian Coca -- You received this message because you are subscribed to the Google Groups "Ansible Project" group. To u

Re: [ansible-project] What should be done for the sorry state of the google.cloud collection?

2022-05-24 Thread Brian Coca
FYI, the collection is 'owned' by Google itself. -- -- Brian Coca -- 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...@googl

[ansible-project] Issues with {{ ansible_hostname }} in task name within a role

2022-05-24 Thread Fco. Javier Lopez
Hello guys ! I do not get the hostname using this fact in task name within a role. Not sure if there is a known issue around this or that I'm doing something wrong. This is my code: main yml file contains this: # facts are collected by default but we want to make sure nobody removes them

Re: [ansible-project] multiple loops in single TASK

2022-05-24 Thread dulhaver via Ansible Project
On 24.05.22 03:08, Dick Visser wrote: This is not possible. ok, thx Also, why would you want to 'nest' the packages? good point, maybe that's just me trying to abstract things over the top On Mon, 23 May 2022 at 18:43, dulhaver via Ansible Project wrote: I want to to install some