[ansible-project] NRM creation

2021-11-29 Thread nitesh shet
Hi, If I need to create a NRM for an object then below which one is a better approach :- Points to be considered is ,The object has 3 different lists which has 3 different keys for each. 1. Creating a single Model with all the 3 lists in one config block .(but how?) 2. Creating 3 different Model

[ansible-project] Model creation

2021-11-29 Thread nitesh shet
Hi, I have seen a generic Model template for creation of Ansible collection which has a config block which contains configurable attributes for the particular object and state has operations supported for the particular object. My query here is, why the Model doesn't contain the whole data-model

[ansible-project] Re: Update variable for each loop iteration?

2021-11-29 Thread Todd Lewis
"What works" and "what you should do" don't always overlap. Here's an idea: --- - name: Combining common list with unique lists hosts: localhost vars: common_vars: - listname1: common name: animal path: home type: dog legs: 4 unique_vars:

[ansible-project] Update variable for each loop iteration?

2021-11-29 Thread Ron T
Hi, I'm trying to combine two dictionaries that have lists of hashes within a loop and then performa actions upon the result of the combined dictionaries. The first dictionary has items that are common variables, and the second has items that are unique. How would I update the final_list

[ansible-project] Re: Accessing contents of a fact in a loop

2021-11-29 Thread Todd Lewis
Before the step that's failing, insert a debug step with the msg: "{{ user_find.json.result.result }}" (really? "result.result"? maybe...) so you (and we) can be certain what your items actually look like. Otherwise, we're just guessing. On Monday, November 29, 2021 at 3:05:37 PM UTC-5

[ansible-project] Accessing contents of a fact in a loop

2021-11-29 Thread lift...@gmail.com
I am traversing our IPA server to get find all users, then I want to loop through all of them to get their password expiration date. I use the IPA API via the uri module and register the variable, but no matter what I try to access the uid of each found user, I get the following error: TASK

Re: [ansible-project] adding a custom dir to a users (not global) PATH via Ansbile

2021-11-29 Thread alex...@gmail.com
Traverse /home and for each user: edit: ~/.bashrc with: export PATH="SOMETHING":$PATH" On Monday, November 29, 2021 at 5:24:47 AM UTC-5 dick@geant.org wrote: > Hi > > Your question seems to be around "installing barman" (no idea what that > is), and while doing that you run into some

Re: [ansible-project] adding a custom dir to a users (not global) PATH via Ansbile

2021-11-29 Thread Dick Visser
Hi Your question seems to be around "installing barman" (no idea what that is), and while doing that you run into some generic system administration issue. Ansible is not really relevant to both the issues. It's used to automate things, but that implies that you already know how to do those

[ansible-project] adding a custom dir to a users (not global) PATH via Ansbile

2021-11-29 Thread dulhaver via Ansible Project
I am trying my luck with installing barman as barman user (non-root) via ansible At the end I need to adust the PATH of the barman user and have managed to add the relevant location (/opt/barman/.local/bin) to the global PATH with the TASK below (from a comment in

Re: [ansible-project] --start-at-task - not working with roles or do I get the syntax wrong?

2021-11-29 Thread Dick Visser
I have not heard of that option before, but in any case, the docs on it ( https://docs.ansible.com/ansible/latest/user_guide/playbooks_startnstep.html#start-at-task) state: > This feature does not work with tasks inside dynamically re-used roles or tasks Also it uses dashed "--start-at-task"

[ansible-project] --start-at-task - not working with roles or do I get the syntax wrong?

2021-11-29 Thread dulhaver via Ansible Project
hy everybody, I am trying a barman installation via Ansible which makes use of 4 roles. Now I want to skip most of the tasks and utilize --start.at-task "name of a task". I am running into a 'task not found' error. I tried variants like --start.at-task "role name"/"name ot a task" without any

Re: [ansible-project] Encrypt files on remote host

2021-11-29 Thread Stefan Hornburg (Racke)
On 26/11/2021 11:39, 'Roman Steinhart' via Ansible Project wrote: Hi Stefan, probably with openssl or gpg. See https://gist.github.com/dreikanter/c7e85598664901afae03fedff308736b https://www.gnupg.org/gph/en/manual/x110.html