[ansible-project] Re: setting up a new system with Ansible

2020-07-22 Thread Gildas Cotomale
Le mercredi 22 juillet 2020 03:22:34 UTC+2, Ed Wong a écrit : > > Here is where i"m a tad bit confused in what I need to do and if someone > can clarify things, I'd be appreciated. > > Is the following process correct? > Yes Ed, the steps you've listed are fine. > > 1) Log on to Alpha and cre

Re: [ansible-project] setting up a new system with Ansible

2020-07-22 Thread Gildas Cotomale
Le mercredi 22 juillet 2020 21:37:03 UTC+2, John Petro a écrit : > > That is pretty close to what I am doing. The only thing I want to do > differently, is that I want to lock the automation account, so that it's > only accepted from a specific host. ( ie. the ansible control node) > > Just t

[ansible-project] Re: Ansible for Cisco switchport interface and 802.1x config

2020-07-22 Thread heinz6...@gmail.com
Hi, you need the cisco_ios module with a jinja template. Waqas Gondal schrieb am Mittwoch, 22. Juli 2020 um 19:58:19 UTC+2: > Hi > > > > I am working on putting Cisco ISE into enforcement mode on production > Cisco switches for 802.1x wired authentication. > > > > Currently the access inte

[ansible-project] Cisco smartport macros

2020-07-22 Thread berti
Hi, I've tried to configure Cisco smartport macros via ansible mit ios_config/cli_config. Both failed with an timeout. It looks like this on the serial console: TN_00sw03(config)#macro auto execute TEST1_CISCO_SWITCH { {..} > if [[ $LINKUP == YES ]] then.else.fi> then then.else.fi> conf

[ansible-project] Cisco Smartport Macros

2020-07-22 Thread berti
Hi, I've tried to configure Cisco smartport macros via ansible mit ios_config/cli_config. Both failed with an timeout. It looks like this on the serial console: TN_lra00sw03(config)#macro auto execute TEST1_LRA_CISCO_SWITCH { {..} > if [[ $LINKUP == YES ]] then.else.fi> then then.else.fi>

Re: [ansible-project] Re: Working around lookup plugin limitation with environment variables

2020-07-22 Thread Dick Visser
Your setting it in one play and then try to use it in another. That won't work. Other question. You run this sts task for all hosts, but is that needed for all of them? On Thu, 23 Jul 2020 at 04:59, Nico H wrote: > Thank you for the proposition, I ve been trying for days to put this in > ever

[ansible-project] Re: Working around lookup plugin limitation with environment variables

2020-07-22 Thread Nico H
Thank you for the proposition, I ve been trying for days to put this in every direction I could but unfortunately 'environment ' was never passed to 'import_role' . I am not sure how to investigate about import_role module and why environment is not supported , seems impossible to reuse sts.cre

[ansible-project] Trouble with python bindings error (libselinux-python not installed) on RHEL8

2020-07-22 Thread Robbie
Hello all. I've been trying to troubleshoot a problem for days and I haven't been able to find anything online that refers to RHEL8/Centos8.I have success running on RHEL/Centos7, but I'm trying to push to the new platform. Ikeep getting this error: TASK [genjson: Generate F5 JSON - Nodes] **

Re: [ansible-project] setting up a new system with Ansible

2020-07-22 Thread John Petro
That is pretty close to what I am doing. The only thing I want to do differently, is that I want to lock the automation account, so that it's only accepted from a specific host. ( ie. the ansible control node) --jp On Tue, Jul 21, 2020 at 9:23 PM Ed Wong wrote: > Hi, > > I've played with Ansi

[ansible-project] Re: sensible-cmdb Default Columns

2020-07-22 Thread Marlon Hester
auto-correct messed up my title. I meant Ansible-cmdb. On Wednesday, July 22, 2020 at 2:45:22 PM UTC-4, Marlon Hester wrote: > > Hello anyone and everyone, > > I've been using ansible-cmdb to generate an inventory webpage. I am trying > to specify the "shown columns" that show by default. I am

[ansible-project] sensible-cmdb Default Columns

2020-07-22 Thread Marlon Hester
Hello anyone and everyone, I've been using ansible-cmdb to generate an inventory webpage. I am trying to specify the "shown columns" that show by default. I am aware of the "-c" option however when I use it, it removes the other unused columns. I want all column buttons to show but I want to b

[ansible-project] Ansible for Cisco switchport interface and 802.1x config

2020-07-22 Thread Waqas Gondal
Hi I am working on putting Cisco ISE into enforcement mode on production Cisco switches for 802.1x wired authentication. Currently the access interfaces all have 'authentication open' which needs to be removed. I have Ansible installed and ready to configure switches. Is there any

Re: [ansible-project] How to debug a community ansible module ?

2020-07-22 Thread Charles Moulliard
Sorry but I don't see how I could debug the code with a breakpoint declared within my IDEA tool using this command "ansible localhost -m ping -a 'data=debugging_session' -vvv" ... On Wed, Jul 22, 2020 at 3:51 PM Matt Martz wrote: > `ansible_collections` is the python module that the code will tr

Re: [ansible-project] How to debug a community ansible module ?

2020-07-22 Thread Matt Martz
`ansible_collections` is the python module that the code will try to load, so you cannot contain that in your PYTHONPATH, you need to set your PYTHONPATH to the directory that contains the ansible_collections directory. fwiw, I wouldn't recommend using this as the primary means to test or debug a

Re: [ansible-project] How to debug a community ansible module ?

2020-07-22 Thread Charles Moulliard
That fails if I try what you suggest as the project (I suppose) is no installed as a collection but git cloned (.venv) ~/code/ansible/ansible_collections $ PYTHONPATH=/Users/cmoullia/code/ansible/ansible_collections python3 community/kubernetes/plugins/modules/k8s_log.py Traceback (most recent ca

Re: [ansible-project] Need help for install java

2020-07-22 Thread Rajeeb sahoo
Hi I have a licensed version of rpm. I had converted .rpm to .deb through alien I tried with manually but it's not happing. are you telling me that I should install xz-utils? I want a specific version like java 8 .deb package. On Wed, Jul 22, 2020 at 4:39 AM Jean-Yves LENHOF wrote: > Hi, >

Re: [ansible-project] working with file

2020-07-22 Thread steveni...@hotmail.fr
OK ! It works, thanks :) Le mercredi 22 juillet 2020 à 11:01:06 UTC+2, brae...@gmail.com a écrit : > On 7/22/20 10:18 AM, steveni...@hotmail.fr wrote: > > Hi, > > > > I have a json file-> cluster_name.json : > > ["cluster1","cluster2","cluster3","cluster4"] > > > > And I want to iterate on every

Re: [ansible-project] How to debug a community ansible module ?

2020-07-22 Thread Abhijeet Kasurde
Try adding PYTHONPATH For me it is like PYTHONPATH=/Volumes/data/src/ansible/lib:/Volumes/data/src/ansible:/Volumes/data/src/collections /Volumes/data/venv3/bin/python On Wed, Jul 22, 2020 at 6:10 PM cmou...@redhat.com wrote: > Hi, > > As the packages to be imported by a python file are prefix

[ansible-project] How to debug a community ansible module ?

2020-07-22 Thread cmou...@redhat.com
Hi, As the packages to be imported by a python file are prefixed as "ansible_collections.", how can we then locally debug an Ansible Module Example: https://github.com/ansible-collections/community.kubernetes/blob/main/plugins/modules/k8s_log.py from ansible_collections.community.kubernetes.pl

[ansible-project] Retrieving a value from NetApp cluster, and assign it to a variable in Playbook

2020-07-22 Thread 'vkk...@yahoo.com' via Ansible Project
New to Ansible, and need your help. I wanted to use a playbook to retrieve a value about a volume upon the entered volume name. Then I assign the value to a variable in Ansible. Based on the value, conditionally determine what next step is in my playbook. Can somebody please illustrate how th

Re: [ansible-project] Creating users in VCD Unsupported API version

2020-07-22 Thread Abhijeet Kasurde
Hi Nagesh, Please set this value https://docs.ansible.com/ansible/latest/reference_appendices/config.html#interpreter-python On Wed, Jul 22, 2020 at 3:50 AM Nagesh sheregar wrote: > Hi Abhijeet, > > i have installed python 3.6 but ansible still showing 2.7, how to fix this > ? > > [root@s605141

Re: [ansible-project] working with file

2020-07-22 Thread Stefan Hornburg (Racke)
On 7/22/20 10:18 AM, steveni...@hotmail.fr wrote: > Hi, > > I have a json file-> cluster_name.json : > ["cluster1","cluster2","cluster3","cluster4"] > > And I want to iterate on every cluster name to obtain some informations so I > use the module vmware_host_service_info. > My playbook is -> vmw

Re: [ansible-project] working with file

2020-07-22 Thread steveni...@hotmail.fr
Hi, I have a json file-> cluster_name.json : ["cluster1","cluster2","cluster3","cluster4"] And I want to iterate on every cluster name to obtain some informations so I use the module vmware_host_service_info. My playbook is -> vmware.yml : --- - name: test hosts: localhost vars_files: -

Re: [ansible-project] Ansible Remote Versioning

2020-07-22 Thread Stefan Hornburg (Racke)
On 7/22/20 9:36 AM, Firesh Bakhda wrote: > Hi JYL, > > This is a great insight you have provided. That would certainly a good way on > how to manipulate the Ansible and Ansible > Tasks on each runs.  > What what it doesn't solve is that how do i populate that fact file with > Tasks that has alre

Re: [ansible-project] Ansible Remote Versioning

2020-07-22 Thread Jean-Yves LENHOF
Hi, I gave you some ideas, I did'nt say this is a good practice to know what tasks has been already ran. When you produce ansible role and playbook, you should ensure that you can run it whenever previous state was and if run more than once without modification results on server should be th

Re: [ansible-project] Ansible Remote Versioning

2020-07-22 Thread Firesh Bakhda
Hi JYL, This is a great insight you have provided. That would certainly a good way on how to manipulate the Ansible and Ansible Tasks on each runs. What what it doesn't solve is that how do i populate that fact file with Tasks that has already been ran. For example, at the end of each Ansibl