Re: [ansible-project] Re: unarchive a file is failing

2018-11-12 Thread anushakeshipeddy4
It is unpacking a tar file successfully but at the same time I am getting below error. Could you please help. {"msg": "The task includes an option with an undefined variable. The error was: 'dict object' has no attribute 'dest_tar'\n\nThe error appears to have been in

Re: [ansible-project] Re: unarchive a file is failing

2018-11-12 Thread Keshipeddy Anusha
Thank you Mohan that worked for me, but may I know why we need to place them in double quotes?? On Tue, Nov 13, 2018, 11:56 AM Mohan L > > You have to quote the dictionary key as well. > > FROM > > - { src_tar: '/home/virtual/xx/sample.tar.gz', dest_tar: '/tmp/sss/' } > > TO > > - { 'src_tar':

[ansible-project] Re: unarchive a file is failing

2018-11-12 Thread Mohan L
You have to quote the dictionary key as well. FROM - { src_tar: '/home/virtual/xx/sample.tar.gz', dest_tar: '/tmp/sss/' } TO - { 'src_tar': '/home/virtual/xx/sample.tar.gz', 'dest_tar': '/tmp/sss/' } Here is the working example. If you write a role and call that role from playbook then

[ansible-project] Re: writing playbook with vars and input parameters

2018-11-12 Thread visar
Hi Experts, Any assistance here. ? On Friday, November 9, 2018 at 7:47:30 PM UTC+5:30, visar wrote: > > Hi Experts, > > Am a beginner to ansible and need all your guidance to learn and > understand ansible at its all functionality and professional way of > playbook creation. > > So Experts,

Re: [ansible-project] Re: Working with Ansible on Windows Hosts

2018-11-12 Thread Jordan Borean
You're missing the most important thing, what's the error you are receiving and whether you kinit can get the user's token. Briefly looking at it - The KDC as has user...@xyz.com, this should be a hostname and not an account of the domain controller - Your inventory file has

Re: [ansible-project] Re: Working with Ansible on Windows Hosts

2018-11-12 Thread Nk Chitturi
krb5.config includedir /etc/krb5.conf.d/ [logging] default = FILE:/var/log/krb5libs.log kdc = FILE:/var/log/krb5kdc.log admin_server = FILE:/var/log/kadmind.log [libdefaults] dns_lookup_realm = false ticket_lifetime = 24h renew_lifetime = 7d forwardable = true rdns = false

Re: [ansible-project] Help needed to spedup the execution of playbook using aync

2018-11-12 Thread Saravanan
Tested the async feature having only one task in the apache_task.yaml file without collecting the result to csv file and it was successful. Can you help to check the server status and append to a file in a single task? On Monday, 12 November 2018 15:25:41 UTC-5, Saravanan wrote: > > Hi Ansible

Re: [ansible-project] Re: Working with Ansible on Windows Hosts

2018-11-12 Thread Jordan Borean
If you've already attempted to connect but failing it would be best to share what you have done as well as any errors you are getting back. I can definitely tell you it is possible but without knowing what issues you are having it's hard to point you in the right direction. Some things that

Re: [ansible-project] Re: Working with Ansible on Windows Hosts

2018-11-12 Thread Nk Chitturi
Thanks Thad, i am already using DSC for server configuration, but after going thorugh Ansible felt like using single component for both linux and windows. my ping play book is not at all working on windows hosts. On Monday, November 12, 2018 at 2:46:33 PM UTC-8, Thad Guidry wrote: > > Since

Re: [ansible-project] Re: Working with Ansible on Windows Hosts

2018-11-12 Thread Thad Guidry
Since your using Windows, you might also want to know that the ecosystem is not only Ansible... DSC also provides the rest of what you often need. https://www.ansible.com/blog/using-the-win_dsc-module-in-ansible Thad +ThadGuidry On Mon, Nov 12, 2018 at 3:52

Re: [ansible-project] Re: call Dockerfiles inside ansible

2018-11-12 Thread Thad Guidry
Yes, I would highly recommend you start using Ansible Container to build your docker containers. You can even use the Ansible template module to automatically create the compose files you’ll need. https://www.ansible.com/blog/ansible-container-project Thad +ThadGuidry

Re: [ansible-project] Can Ansible execute a Dockerfile on Docker to setup platforms for PXE boots?

2018-11-12 Thread Thad Guidry
Lots of ways to handle this... What you are after is called "baremetal provisioning". https://www.ansible.com/use-cases/provisioning Start with reading this thread... https://www.reddit.com/r/ansible/comments/7c7lsg/install_os_on_bare_metal/ And lots of existing roles already on Ansible Galaxy to

[ansible-project] Re: Working with Ansible on Windows Hosts

2018-11-12 Thread Nk Chitturi
Thanks Jordan, yeah i am trying to use windows as hosts and i spent lot of time setting up windows machines as hosts. i tried kerberos as well but no luck. On Monday, November 12, 2018 at 1:32:59 PM UTC-8, Jordan Borean wrote: > > Depends on what you mean by working on Windows, Ansible can

[ansible-project] Re: call Dockerfiles inside ansible

2018-11-12 Thread EspressoBeanies
Maybe this works: https://docs.ansible.com/ansible-container/migrating.html#migrating-from-a-dockerfile -- 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: Working with Ansible on Windows Hosts

2018-11-12 Thread Jordan Borean
Depends on what you mean by working on Windows, Ansible can remotely connect to a Windows host and execute modules against that. We have numerous docs and a quick Google search will give you lots of info and blog posts detailing how this can be done. If you want to know if you can run Ansible

[ansible-project] Re: call Dockerfiles inside ansible

2018-11-12 Thread EspressoBeanies
>From seeing the available Docker modules, I'd say you can build Docker images, I'm just not sure if you can use Ansible to execute Dockerfiles. The documentation would say so, but it's a bit unclear as to how to achieve this. Not enough good examples. On Wednesday, August 22, 2018 at 1:14:35

[ansible-project] Can Ansible execute a Dockerfile on Docker to setup platforms for PXE boots?

2018-11-12 Thread EspressoBeanies
I'd like to setup an HTTP server on a Docker image to serve as a platform for PXE booting and I don't see a clear way for Ansible to be able to execute a Dockerfile on a local Docker instance to spawn an HTTP server. I don't know if it'd be effective to continuously build and destroy a docker

[ansible-project] Working with Ansible on Windows Hosts

2018-11-12 Thread Nk Chitturi
Hello All, did anyone figured out working with ansible on windows host, if so please give me the process and info how you guys get this working on windows. thanks, Narmada -- You received this message because you are subscribed to the Google Groups "Ansible Project" group. To unsubscribe

Re: [ansible-project] Help needed to spedup the execution of playbook using aync

2018-11-12 Thread Saravanan Ponnusamy
Hi Ansible Expers, Can you please share your valuable suggestions/ inputs to improve the performance of the playbook? > On Nov 12, 2018, at 1:04 PM, Saravanan wrote: > > Hi Team, > Herewith I am sharing my core playbook and another yaml playbook used for > iteration to get the apache server

Re: [ansible-project] Re: need to replace a line in config file

2018-11-12 Thread vivek vijayan
Hi Dick, By editing this configuration xml file I am disabling the default basicregistry file user authentication which is local and I am enabling the LDAP setting by commenting out. Once the LDAP line got uncommented I have my own LDAP settings in the ldapuser registry file. Also in some

Re: [ansible-project] Apply action for each regexp match found on same line

2018-11-12 Thread Thad Guidry
OK, sounds good, yes a script should do the trick. You can even write it in Python and later contribute a nice Ansible module :) :) Here's inspiration: https://docs.ansible.com/ansible/latest/modules/list_of_cloud_modules.html#vmware

Re: [ansible-project] Re: need to replace a line in config file

2018-11-12 Thread Dick Visser
Hi Visar You keep thinking in terms of "commenting out lines" in your XML configuration file. But what you really want (although you might not realise it), is to configure your application server the right way. This playbook does exactly that. Ignore what is commented out - like your application

[ansible-project] cant run shell script with arguments

2018-11-12 Thread visar
Hello Experts. i tried both command and shell module to execute the playbook for running my application setup. There i have to add some arguments with the script, as one input file as response.properties, and one application url and my domain credentials along with it. below is the playbook

[ansible-project] Help needed to spedup the execution of playbook using aync

2018-11-12 Thread Saravanan
Hi Team, Herewith I am sharing my core playbook and another yaml playbook used for iteration to get the apache server status, storing them to a file. This playbook takes longer time to complete the task on all hosts. To speedup he execution, I would like to include async in the play. Please

[ansible-project] unarchive a file is failing

2018-11-12 Thread anushakeshipeddy4
Hi Team, I am trying to unarchive a file is failing with below errors. Could someone please look into it. *Playbook:* --- - hosts: all vars_files: - /etc/ansible/xx/xyz/vars/main.yml tasks: - name: test unarchive: src: "{{ item.src_tar }}" dest: “{{

Re: [ansible-project] Re: need to replace a line in config file

2018-11-12 Thread visar
Hello Dick, Now this is the output. Here ldapUserRegistry line is repeating twice where one should be basicUserRegistry xml file which should be commented.. Thanks in advance for your help here On Monday, November 12, 2018 at 10:53:39 PM UTC+5:30, visar

Re: [ansible-project] Re: need to replace a line in config file

2018-11-12 Thread visar
Hello Dick, Yes, You are right that the given play is working . The playbook is making changes on the xml file, but not as expected. Its making double entry for same ldap settings. one is commented another is uncommented. But here I want a result like comment only the basic user

Re: [ansible-project] Apply action for each regexp match found on same line

2018-11-12 Thread John Harmon
On Saturday, November 10, 2018 at 9:48:17 AM UTC-7, Thad Guidry wrote: > > John, > > What problem are you actually trying to solve ? Generating random numbers > especially around MAC certainly can get you in trouble. Are you trying to > generate a Pool and apply something 1 time from that

Re: [ansible-project] Apply action for each regexp match found on same line

2018-11-12 Thread John Harmon
On Saturday, November 10, 2018 at 2:07:52 AM UTC-7, Kai Stian Olstad wrote: > > On Wednesday, 7 November 2018 17:36:43 CET John Harmon wrote: > > Desired (As shown above, keep first three octets of mac, change 4th to > AA, > > and the last two are random numbers between 10-99): > > vif =

Re: [ansible-project] Re: need to replace a line in config file

2018-11-12 Thread Dick Visser
On Fri, 9 Nov 2018 at 13:27, visar wrote: > > Hello Visser, > > Appreciate your time for checking this. > > Here i am little confused that, > > Here I just want to modify the server.xml file only. > (comment basicuserregistry.xml and uncomment ldapuseruserregistry.xml file). > > Both the files

Re: [ansible-project] Ansible command module giving errors in playbook

2018-11-12 Thread Brian Coca
That does not modify the command task, so i expect it to keep giving the same error. -- -- 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

Re: [ansible-project] Ansible command module giving errors in playbook

2018-11-12 Thread visar
Hello Brian, Thanks for your valuable advise, i modifed my playbook with vars as the path of the installer as below and still have the error. --- - name: Silent installation of "IBM Installation Manager" hosts: IHS vars: Pack_dir:

Re: [ansible-project] Ansible command module giving errors in playbook

2018-11-12 Thread Brian Coca
Ansible uses a 'batch login' by default, which might not source the same files as an interactive one and not have the same PATH set, so either use full path for installc or use the `environement:` keyword to ensure the correct PATH is set. -- -- Brian Coca -- You received this message

[ansible-project] Ansible command module giving errors in playbook

2018-11-12 Thread visar
0down votefavorite I am creating a playbook to silently execute a installation package using Command module. But here I am getting playbook execution error. Below is my playbook sample. Here my

Re: [ansible-project] Re: need to replace a line in config file

2018-11-12 Thread visar
I tried with below play book but its not changing anything but playbook is running without any issues. - name: LDAP Settings hosts: myserver vars: mark_1: 'include location="conf/basicUserRegistry.xml"/' mark_2: 'include location="conf/ldapUserRegistry.xml"/' tasks: - replace:

Re: [ansible-project] Is there a way to access a play's vars section?

2018-11-12 Thread Brian Coca
To save vars to a yaml file i would just use a template task, unsure what you are doing or why, but this seems wrong to me. On the import_tasks, include_tasks .. no clue what 'undefined alias' is nor can i reproduce it, you need to give a full error with -vvv (which will include traceback) --

Re: [ansible-project] Cron module

2018-11-12 Thread f . second
Thanks for your answer. It's confirm that, not need Python module My issue was due on space in my playbook. :( Best regards. Fabien Le lundi 12 novembre 2018 13:59:16 UTC+1, Felix Fontein a écrit : > > Hi, > > > It's not possible to install cron module for manage crontab. > > >

Re: [ansible-project] Cron module

2018-11-12 Thread 'Felix Fontein' via Ansible Project
Hi, > It's not possible to install cron module for manage crontab. > https://docs.ansible.com/ansible/2.7/modules/cron_module.html?highlight=cron#requirements it is not a Python requirement. You usually don't need to install anything. I've been using the cron module for years without having

[ansible-project] Cron module

2018-11-12 Thread f . second
Hello, It's not possible to install cron module for manage crontab. https://docs.ansible.com/ansible/2.7/modules/cron_module.html?highlight=cron#requirements pip install cron I've this issue : playbook pip install cron -vvv Created temporary directory: /tmp/pip-ephem-wheel-cache-InQUZ3

Re: [ansible-project] Re: Logging per playbook file

2018-11-12 Thread Sorin Work
Thank you! I'l look into that. On Friday, 9 November 2018 12:00:40 UTC+1, Thad Guidry wrote: > > Ansible only picks up the first ansible.cfg found. > > > "Changes can be made and used in a configuration file which will be > searched for in the following order: > > ANSIBLE_CONFIG