[ansible-project] Re: Managing postgres functions/tirggers with ansible

2024-04-17 Thread Roland Müller
Hello, I think the postgresql ansible module is for administrating postgresql or enabling the execution of scripts or queries rather then providing a some layer around DDL or DML commands for PostgreSQL. You should be able to use postgresql_query_module or postgresql_script_module for executi

Re: [ansible-project] condition in playbook

2024-04-17 Thread Thirumalai Raja A
let me try this thanks, On Wed, 17 Apr 2024 at 19:31, Todd Lewis wrote: > I don't know what consumes this ("template_run"?), but you could try this: > extra_vars: > sat_client_id: "{{ sat_client_id }}" > sat_client_secret: "{{ sat_client_secret }}" > websec

[ansible-project] Managing postgres functions/tirggers with ansible

2024-04-17 Thread Dick Visser
Hi,, I'm trying to manage a postgres database with ansible. Database OK, users OK, tables OK. But now I have a table which has a field that should auto update with NOW() upon changes. So far that requires SQL statements like this: CREATE FUNCTION ... CREATE TRIGGER... I looked at https://docs.a

[ansible-project] ModuleNotFoundError: No module named 'ansible.module_utils.common.yaml'

2024-04-17 Thread Gökberk Gündüz
hi, I was trying to upgrade ansible to the newest version. But when I test the my roles on molecule, I've got something which I could not find any solution. Here is the pip freeze; (test) gg@gg-berk:~/ansible$ pip freeze aiofiles==23.2.1 aiohttp==3.9.5 aiosignal==1.3.1 alabaster==0.7.16 ansible==

Re: [ansible-project] condition in playbook

2024-04-17 Thread Brian Coca
This won't work as playbooks themselves are not jinja2 evaluated, only keys inside a play are {% if oracle in job_temp_name %} ansible_distribution: "RedHat" patch_enablerepo: "value" standard_enablerepo: "value" {% endif %} An alternative would b

[ansible-project] Re: Need help in setting ansible for sonicwall backups

2024-04-17 Thread dbs34
Hello! I can offer some advice. In my findings, often there are no vendor canned, provided modules so you have to use the netcommon.cli module which works just as well. I have successfully deployed playbooks for cisco ios, cisco asa, dell, wlcs and nxos. Here is one playbook I use for my asa

Re: [ansible-project] condition in playbook

2024-04-17 Thread Todd Lewis
I don't know what consumes this ("template_run"?), but you could try this: extra_vars: sat_client_id: "{{ sat_client_id }}" sat_client_secret: "{{ sat_client_secret }}" websec_prod_id: "{{ websec_prod_id }}" websec_prod_secret: "{{ websec_prod_secret }}" radius_secret: "{{ radius_secret }}" ansibl

[ansible-project] Need help in setting ansible for sonicwall backups

2024-04-17 Thread Rahul Kumar
Hello All, I need help in setting ansible to take Sonicwall firewall backups. Anyone, who is willing to help me is greatly appreciated. Thanks, -- You received this message because you are subscribed to the Google Groups "Ansible Project" group. To unsubscribe from this group and stop recei

Re: [ansible-project] condition in playbook

2024-04-17 Thread Dick Visser
Hii, I have never seen a task called "template_run", is this something custom that you built? On Wed, 17 Apr 2024 at 09:22, Thirumalai Raja A wrote: > > hi all, > > below is my playbook ia m trying to add some variable in extra_vars: argument > and based on the condition but its giving error can

[ansible-project] condition in playbook

2024-04-17 Thread Thirumalai Raja A
hi all, below is my playbook ia m trying to add some variable in extra_vars: argument and based on the condition but its giving error can some guide me how can we mention this like if string 'oracle' is there in template_name variable i need to add some extra var otherwise it should not add.