[ansible-project] playbook to compare and update hostvars in host file

2020-09-02 Thread harsh chawda
Hello All,

I am trying to update /etc/hosts file if there is any changes in the host 
extra variables by comparing it from a csv file

[windows]
Server01.test.com ansible_user="admin" ansible_password="password"
Server02.test.com ansible_user="admin" ansible_password="Welcome"

So suppose the password is changed for the systems . 

*password.csv*
Server01.test.com  passwordNew
Server02.test.com  WelcomeNew

So, how to compare and change the values in the existing host file.

Please if anyone having any idea or script for this will be a great help 
for me.

Thanks in advance

*Regards*
*Harsh*


-- 
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...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/ansible-project/63fa30be-ce6c-4485-8af3-838a7cf44efao%40googlegroups.com.


Re: [ansible-project] Host SSH key not recognized when trying to SSH into remote repository using Ansible playbook

2020-09-02 Thread Dick Visser
Or: key is ok but it's not being used because of an ssh misconfig

On Thu, 3 Sep 2020 at 06:44, Dick Visser  wrote:

> Sounds like a permission issue somewhere.
> Can you manually sudo to whatever user your playbook is using and clone
> the repo?
> Key permissions ok?
> Correct user?
>
>
>
> On Wed, 2 Sep 2020 at 23:34, Erick Sun  wrote:
>
>> Hello, thanks for taking a look!  I am trying to install needed software
>> on hosts running RHEL 7.x (Docker, Python, Intel Parallel Studio).  During
>> play to download Intel, the play is designed to ssh into and clone from
>> remote Git repo.  It has been verified that the local host' ssh key is
>> known by remote server and also the server's ssh key is known to local
>> host, although local host is not able to read from remote.  Without going
>> into too much detail, here is the set of plays being run in playbook.yml,
>> as well as the inventory in hosts.yml.  The playbook breaks at the  "Clone
>> cots_lfs repo" play:
>>
>>
>> ##playbook.yml
>> ---
>> - hosts: all
>>   gather_facts: yes
>>   tasks:
>>
>> ###Set of plays that checks the host OS, RAM, and scratch Disk Space
>> #Grab the Distribution and Version and check it is between 7.x and 8.0
>> - name: Distribution
>>   ...
>>
>> - name: Distribution version
>>   ...
>>
>> - name: Check that the Red Hat Version >= 7.x and < 8
>>   ...
>>
>> #Check the Ram and that there's at least xxx MB
>> - name: RAM
>>   ...
>>
>> - name: Check that the System Ram is > xxx MB
>>   ...
>>
>> #Check HD space of /local_path and that there's at least xxx MB.
>> - name: Disk Space
>>   ...
>>
>> - name: Check that Disk Space is > xxx MB.
>>   ...
>>
>> ###Set of plays that checks the host RPMs and Services for Docker
>> #Get RPM and Service Facts
>> - name: Populate Host RPM Package Facts
>>   ...
>>
>> - name: Populate Host Service Facts
>>   ...
>>
>> #Docker Plays
>> - name: Check if Docker is installed
>>   ...
>>
>> - name: Install Docker Dependencies if needed
>>   ...
>>
>> - name: Add the Public Docker Repo if needed
>>   ...
>>
>> - name: Install Docker Dependencies if needed
>>   ...
>>
>> - name: Install Docker service 18.x
>>   ...
>>
>> - name: Set the Docker http proxy file
>>   ...
>>
>> - name: Set the Docker daemon file
>>   ...
>>
>> - name: Ensure Docker group is created on host
>>   ...
>>
>> - name: Add users to Docker group
>>   ...
>>
>> - name: Initial Start of Docker Service
>>   ...
>>
>> - name: Set permissions on /var/run/docker.sock to 0666
>>   ...
>>
>> - name: Stop Docker Service
>>   ...
>>
>> - name: Reload Docker Service
>>   ...
>>
>> - name: Enable and Start Docker Service
>>   ...
>>
>> - name: Print Docker Service Info
>>   ...
>>
>> ###Set of plays that checks the host RPMs and Services for Python3
>> #Check Python plays
>> - name: Check for Python3
>>   ...
>>
>> - name: Install Python3 if needed
>>   ...
>>
>> - name: Check for Python3-Pip
>>   ...
>>
>> - name: Install Python3-Pip if needed
>>   ...
>>
>> - name: Check for Python-Virtualenv
>>   ...
>>
>> - name: Install
>>
>>
>>
>> Python-Virtualenv   if needed
>>   ...
>>
>> - name: Run script to create Python Virtual environment
>>   ...
>>
>> ###Set of plays that checks the host's git lfs installation
>> - name: Install git-lfs if needed
>>   ...
>>
>> ###Set of plays that installs Intel
>> - name: Check if Intel is installed in /opt/
>>   ...
>>
>> - name: Clone cots_lfs repo
>>  clone:  yes
>>  repo:  'ssh://'
>>  dest:  /local_path/cots_lfs
>>  version:  intel_parallel_studio_full
>>  update:  yes
>>  clone:  yes
>>  force:  yes
>>when:  not intel_exists.stat.exists
>>
>> - name: Install Intel
>>   ...
>>
>> ###Set of plays that modifies the hosts /etc/ files
>> - name: Run modify system files script
>>   ...
>>
>> - name: Restart host if system files have been modified
>>   ...
>>
>> - name: Restart Docker service if host was rebooted
>>   ...
>>
>>
>> ##hosts.yml
>> ---
>> all:
>>hosts:
>>   localhost
>>children:
>>   watermarked:
>>  vars:
>> proxy:  
>>  hosts:
>> Workstation1:
>>ansible_host:  
>> Workstation2:
>>ansible_host:  
>> ...
>>
>>   nonwatermarked:
>>  hosts:
>> Workstation1:
>>ansible_host:  
>> Workstation2:
>>ansible_host:  
>> ...
>>
>>   offline:
>>  hosts:
>> 
>>
>>
>>
>> Thanks,
>> Erick
>>
>>
>>
>> On Wednesday, September 2, 2020 at 1:37:01 AM UTC-7 dick@geant.org
>> wrote:
>>
>>> You need to give more info. Playbooks, inventory, what are you trying
>>>
>>>
>>> to achieve, etc.
>>>
>>>
>>>
>>>
>>>
>>> On Tue, 1 Sep 2020 at 23:48, Erick Sun  wrote:
>>>
>>>
>>> >
>>>
>>>
>>> > Host SSH key not recognized when trying to SSH into remote repository
>>> using Ansible playbook. Remote repository was verified to have the correct
>>> SSH key from host, but 

Re: [ansible-project] Host SSH key not recognized when trying to SSH into remote repository using Ansible playbook

2020-09-02 Thread Dick Visser
Sounds like a permission issue somewhere.
Can you manually sudo to whatever user your playbook is using and clone the
repo?
Key permissions ok?
Correct user?



On Wed, 2 Sep 2020 at 23:34, Erick Sun  wrote:

> Hello, thanks for taking a look!  I am trying to install needed software
> on hosts running RHEL 7.x (Docker, Python, Intel Parallel Studio).  During
> play to download Intel, the play is designed to ssh into and clone from
> remote Git repo.  It has been verified that the local host' ssh key is
> known by remote server and also the server's ssh key is known to local
> host, although local host is not able to read from remote.  Without going
> into too much detail, here is the set of plays being run in playbook.yml,
> as well as the inventory in hosts.yml.  The playbook breaks at the  "Clone
> cots_lfs repo" play:
>
>
> ##playbook.yml
> ---
> - hosts: all
>   gather_facts: yes
>   tasks:
>
> ###Set of plays that checks the host OS, RAM, and scratch Disk Space
> #Grab the Distribution and Version and check it is between 7.x and 8.0
> - name: Distribution
>   ...
>
> - name: Distribution version
>   ...
>
> - name: Check that the Red Hat Version >= 7.x and < 8
>   ...
>
> #Check the Ram and that there's at least xxx MB
> - name: RAM
>   ...
>
> - name: Check that the System Ram is > xxx MB
>   ...
>
> #Check HD space of /local_path and that there's at least xxx MB.
> - name: Disk Space
>   ...
>
> - name: Check that Disk Space is > xxx MB.
>   ...
>
> ###Set of plays that checks the host RPMs and Services for Docker
> #Get RPM and Service Facts
> - name: Populate Host RPM Package Facts
>   ...
>
> - name: Populate Host Service Facts
>   ...
>
> #Docker Plays
> - name: Check if Docker is installed
>   ...
>
> - name: Install Docker Dependencies if needed
>   ...
>
> - name: Add the Public Docker Repo if needed
>   ...
>
> - name: Install Docker Dependencies if needed
>   ...
>
> - name: Install Docker service 18.x
>   ...
>
> - name: Set the Docker http proxy file
>   ...
>
> - name: Set the Docker daemon file
>   ...
>
> - name: Ensure Docker group is created on host
>   ...
>
> - name: Add users to Docker group
>   ...
>
> - name: Initial Start of Docker Service
>   ...
>
> - name: Set permissions on /var/run/docker.sock to 0666
>   ...
>
> - name: Stop Docker Service
>   ...
>
> - name: Reload Docker Service
>   ...
>
> - name: Enable and Start Docker Service
>   ...
>
> - name: Print Docker Service Info
>   ...
>
> ###Set of plays that checks the host RPMs and Services for Python3
> #Check Python plays
> - name: Check for Python3
>   ...
>
> - name: Install Python3 if needed
>   ...
>
> - name: Check for Python3-Pip
>   ...
>
> - name: Install Python3-Pip if needed
>   ...
>
> - name: Check for Python-Virtualenv
>   ...
>
> - name: Install
>
>
>
> Python-Virtualenv   if needed
>   ...
>
> - name: Run script to create Python Virtual environment
>   ...
>
> ###Set of plays that checks the host's git lfs installation
> - name: Install git-lfs if needed
>   ...
>
> ###Set of plays that installs Intel
> - name: Check if Intel is installed in /opt/
>   ...
>
> - name: Clone cots_lfs repo
>  clone:  yes
>  repo:  'ssh://'
>  dest:  /local_path/cots_lfs
>  version:  intel_parallel_studio_full
>  update:  yes
>  clone:  yes
>  force:  yes
>when:  not intel_exists.stat.exists
>
> - name: Install Intel
>   ...
>
> ###Set of plays that modifies the hosts /etc/ files
> - name: Run modify system files script
>   ...
>
> - name: Restart host if system files have been modified
>   ...
>
> - name: Restart Docker service if host was rebooted
>   ...
>
>
> ##hosts.yml
> ---
> all:
>hosts:
>   localhost
>children:
>   watermarked:
>  vars:
> proxy:  
>  hosts:
> Workstation1:
>ansible_host:  
> Workstation2:
>ansible_host:  
> ...
>
>   nonwatermarked:
>  hosts:
> Workstation1:
>ansible_host:  
> Workstation2:
>ansible_host:  
> ...
>
>   offline:
>  hosts:
> 
>
>
>
> Thanks,
> Erick
>
>
>
> On Wednesday, September 2, 2020 at 1:37:01 AM UTC-7 dick@geant.org
> wrote:
>
>> You need to give more info. Playbooks, inventory, what are you trying
>>
>>
>> to achieve, etc.
>>
>>
>>
>>
>>
>> On Tue, 1 Sep 2020 at 23:48, Erick Sun  wrote:
>>
>>
>> >
>>
>>
>> > Host SSH key not recognized when trying to SSH into remote repository
>> using Ansible playbook. Remote repository was verified to have the correct
>> SSH key from host, but still wouldn't recognize host when trying to clone
>> from the repository. Ran Ansible on 15 hosts, 13 were successful, 1 failed
>> to clone from remote repo even though they were configured the same. Here
>> is the actual error received. Can anyone help, please? Thx
>>
>>
>> >
>>
>>
>> > fatal: [Host]: FAILED! => {"changed": false, "cmd": 

Re: [ansible-project] Help with async tasks.

2020-09-02 Thread Guannan Sun
Thank you!
Even I have not used gnu parallel before, I'll also take it into 
consideration.
If have any progress, I'd like to share.
Best reagards!

在2020年9月2日星期三 UTC+8 上午8:07:53 写道:

> well other option (i used only once) is run the shell command with gnu 
> parallel .
> its pretty amazing! but i pretty stiff learning curve.
> maybe you could , give it a chance.
>
> best regards!
>
> El mar., 1 sept. 2020 a las 4:19, Guannan Sun () 
> escribió:
>
>> Thank you for your response. 
>> I've tried to add 'strategy: free' in my playbook, however it seems not 
>> work as my expectation. I think it may because there is only single host in 
>> my scenario, while 'strategy: free' works well in scenario of multi hosts 
>> and multi tasks.
>> We're now trying to run multi jobs at the same time on AWX. One jobs call 
>> the role 'create_site' and loop for 5 configuration files, so that 20 jobs 
>> will cover 100 configuration files. It seems work in my scenario.
>> Thank you anyway, and good-looking signiture :)
>>
>> 在2020年9月1日星期二 UTC+8 上午4:10:14 写道:
>>
>>> Hi ! maybe something like this :
>>>
>>> https://medium.com/developer-space/parallel-playbook-execution-in-ansible-30799ccda4e0
>>>
>>> El lun., 31 ago. 2020 a las 6:57, Guannan Sun () 
>>> escribió:
>>>
 Thank you for your response.
 Well, in my condition, I using 'create_site' role to create a site in a 
 netbox. It will create a site with name, region, and some other fields, 
 associate some devices and vlans with the site.
 You may just treat 'create_site' as a role execute some tasks in serial.

 在2020年8月31日星期一 UTC+8 下午5:45:56 写道:

> On 8/31/20 11:38 AM, Guannan Sun wrote: 
> > Dear Tech Team, 
> > 
> > I'm Guannan from China. I'm new to Ansible and looking for some 
> technical help. 
> > Actually I'm looking for a method to execute one role in parallel 
> with loops of different configuration files. For 
> > example, I want to create 100 sites using role "create_site" with 
> 100 different configuration files. I simply write a 
> > playbook like this: 
> > 
> > - hosts: localhost 
> >   gather_facts: no 
> >   tasks: 
> > - name: register files 
> >   shell: "find /tmp/site_files -name '*.yml' | sort" 
> >   register: file_names 
> > 
> > - include_role: 
> > name: create_site 
> > vars_from: "{{ item }}" 
> >   with_items: "{{ file_names.stdout_lines }}" 
> > 
> > This will create 100 sites in serial. If create one site take 2 
> minutes, then the whole playbook will take over 200 
> > minutes. I found 'async' option when execute tasks, however it seems 
> only used for async jobs on different hosts. Do you 
> > guys have experience or methods on how to execute one role with 
> different configuration files in parallel? Please send 
> > me E-mails. 
> > Much thanks for your help! 
>
> What is the "create_site" role actually doing? 
>
> Regards 
> Racke 
>
> > 
> > -- 
> > 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-proje...@googlegroups.com  ansible-proje...@googlegroups.com>. 
> > To view this discussion on the web visit 
> > 
> https://groups.google.com/d/msgid/ansible-project/7d012eec-95de-48c3-8b8a-d32928170eacn%40googlegroups.com
>  
> > <
> https://groups.google.com/d/msgid/ansible-project/7d012eec-95de-48c3-8b8a-d32928170eacn%40googlegroups.com?utm_medium=email_source=footer>.
>  
>
>
>
> -- 
> Ecommerce and Linux consulting + Perl and web application programming. 
> Debian and Sympa administration. Provisioning with Ansible. 
>
> -- 
 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-proje...@googlegroups.com.
 To view this discussion on the web visit 
 https://groups.google.com/d/msgid/ansible-project/4a67d662-278a-4070-9091-18778ae53befn%40googlegroups.com
  
 
 .

>>>
>>>
>>> -- 
>>>
>>>   ::: (\(\
>>>   *: (=' :') :*
>>>   ... (,('')('')
>>>   mar...@etcheverri.com
>>>   Consultoria de sistemas
>>>  
>>>
>>>
>>> -- 
>> 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-proje...@googlegroups.com.
>>
> To view 

Re: [ansible-project] Host SSH key not recognized when trying to SSH into remote repository using Ansible playbook

2020-09-02 Thread Erick Sun
Hello, thanks for taking a look!  I am trying to install needed software on 
hosts running RHEL 7.x (Docker, Python, Intel Parallel Studio).  During 
play to download Intel, the play is designed to ssh into and clone from 
remote Git repo.  It has been verified that the local host' ssh key is 
known by remote server and also the server's ssh key is known to local 
host, although local host is not able to read from remote.  Without going 
into too much detail, here is the set of plays being run in playbook.yml, 
as well as the inventory in hosts.yml.  The playbook breaks at the  "Clone 
cots_lfs repo" play:


##playbook.yml
---
- hosts: all
  gather_facts: yes
  tasks:

###Set of plays that checks the host OS, RAM, and scratch Disk Space
#Grab the Distribution and Version and check it is between 7.x and 8.0
- name: Distribution
  ...

- name: Distribution version
  ...

- name: Check that the Red Hat Version >= 7.x and < 8
  ...

#Check the Ram and that there's at least xxx MB
- name: RAM
  ...

- name: Check that the System Ram is > xxx MB
  ...

#Check HD space of /local_path and that there's at least xxx MB.
- name: Disk Space
  ...

- name: Check that Disk Space is > xxx MB.
  ...

###Set of plays that checks the host RPMs and Services for Docker
#Get RPM and Service Facts
- name: Populate Host RPM Package Facts
  ...

- name: Populate Host Service Facts
  ...

#Docker Plays
- name: Check if Docker is installed
  ...

- name: Install Docker Dependencies if needed
  ...

- name: Add the Public Docker Repo if needed
  ...

- name: Install Docker Dependencies if needed
  ...

- name: Install Docker service 18.x
  ...

- name: Set the Docker http proxy file
  ...

- name: Set the Docker daemon file
  ...

- name: Ensure Docker group is created on host
  ...

- name: Add users to Docker group
  ...

- name: Initial Start of Docker Service
  ...

- name: Set permissions on /var/run/docker.sock to 0666
  ...

- name: Stop Docker Service
  ...

- name: Reload Docker Service
  ...

- name: Enable and Start Docker Service
  ...

- name: Print Docker Service Info
  ...

###Set of plays that checks the host RPMs and Services for Python3
#Check Python plays
- name: Check for Python3
  ...

- name: Install Python3 if needed
  ...
  
- name: Check for Python3-Pip
  ...

- name: Install Python3-Pip if needed
  ...

- name: Check for Python-Virtualenv
  ...

- name: Install  Python-Virtualenv   if needed
  ...

- name: Run script to create Python Virtual environment
  ... 

###Set of plays that checks the host's git lfs installation
- name: Install git-lfs if needed
  ... 

###Set of plays that installs Intel
- name: Check if Intel is installed in /opt/
  ... 

- name: Clone cots_lfs repo
 clone:  yes  
 repo:  'ssh://'
 dest:  /local_path/cots_lfs
 version:  intel_parallel_studio_full
 update:  yes
 clone:  yes
 force:  yes  
   when:  not intel_exists.stat.exists 

- name: Install Intel
  ... 

###Set of plays that modifies the hosts /etc/ files
- name: Run modify system files script
  ... 

- name: Restart host if system files have been modified
  ... 

- name: Restart Docker service if host was rebooted
  ... 


##hosts.yml
---
all:
   hosts:
  localhost
   children:
  watermarked:
 vars:
proxy:  
 hosts:
Workstation1:
   ansible_host:  
Workstation2:
   ansible_host:  
...

  nonwatermarked:
 hosts:
Workstation1:
   ansible_host:  
Workstation2:
   ansible_host:  
...

  offline:
 hosts:




Thanks,
Erick



On Wednesday, September 2, 2020 at 1:37:01 AM UTC-7 dick@geant.org 
wrote:

> You need to give more info. Playbooks, inventory, what are you trying 
> to achieve, etc. 
>
> On Tue, 1 Sep 2020 at 23:48, Erick Sun  wrote: 
> > 
> > Host SSH key not recognized when trying to SSH into remote repository 
> using Ansible playbook. Remote repository was verified to have the correct 
> SSH key from host, but still wouldn't recognize host when trying to clone 
> from the repository. Ran Ansible on 15 hosts, 13 were successful, 1 failed 
> to clone from remote repo even though they were configured the same. Here 
> is the actual error received. Can anyone help, please? Thx 
> > 
> > fatal: [Host]: FAILED! => {"changed": false, "cmd": "/usr/bin/git clone 
> --origin origin 'ssh:' /local_path", "msg": "FIPS mode 
> initialized\r\nDisabling GSSAPIKeyExchange. Not usable in FIPS 
> mode\r\nPermission denied (publickey).\r\nfatal: Could not read from remote 
> repository.\n\nPlease make sure you have the correct access rights\nand the 
> repository exists.", "rc": 128, "stderr": "FIPS mode 
> initialized\r\nDisabling GSSAPIKeyExchange. Not usable in FIPS 
> mode\r\nPermission denied (public key).\r\nfatal: Could not read from 
> remote repository.\n\nPlease make sure you have the corr ect access 

[ansible-project] Ansible task not starting up custom node.js script with either shell or command module

2020-09-02 Thread Sebastian Collins
Hi,

Any ideas where I am going wrong here?

I have a web server task which uses shell to start apache no problem:

- hosts: webservers
remote_user: root
become_user: test
become: True
tasks:
  - name: Task18 - Start webservers back up
shell: ./apache/bin/apachectl start
tags:
  - startweb

I have made a similar task to try start node for which I pass in the same 
'start' arguement

- hosts: nodes
remote_user: root
become_user: test
become: True
tasks:
  - name:  Start node back up
shell: ./***/***/init.d/etc.d/control.postcodesio.nodejs.sh start
tags:
  - startnode

This task fails with : 

 "msg": "non-zero return code", "rc": 127, "start": "2020-09-02 
19:07:49.395993", "stderr": "sh: control.postcodesio.nodejs.sh: No such 
file or directory",

This script definitely exists in this location and works if triggered 
manually:

./control.postcodesio.nodejs.sh start
Starting NodeJS: 26182
 NodeJS instance running


I have tried a different approach but I still get the same  No such file or 
directory

 tasks:
  - name:  Change Directory
command: cd /***/***/init.d/etc.d/

  - command: "ls /***/***/init.d/etc.d/"
register: dir_out

  - debug: var={{item}}
with_items: dir_out.stdout_lines

   - name: start nodejs 
 command: sh control.postcodesio.nodejs.sh start

The output of the debug step above confirms the presence of the script as 
shown in the output below so i really don't understand why it says the "
control.postcodesio.nodejs.sh" can't be found?

:
TASK  Change Directory] 
***
changed: [hostname]
changed: [h ostname]

TASK [command] 
*
changed: [ hostname  ]
changed: [hostname]

TASK [debug] 
***
ok: [hostname] => (item=dir_out.stdout_lines) => {
"changed": false,
"dir_out.stdout_lines": [
"control.apache.sh",
"control.postcodesio.nodejs.sh"
],
"item": "dir_out.stdout_lines"
}
ok: [hostname] => (item=dir_out.stdout_lines) => {
"changed": false,
"dir_out.stdout_lines": [
"control.apache.sh",
"control.postcodesio.nodejs.sh"
],
"item": "dir_out.stdout_lines"
}

TASK start nodejs 
*
fatal: [hostname]: FAILED! => {"changed": true, "cmd": ["sh", "
control.postcodesio.nodejs.sh", "start"], "delta": "0:00:00.007772", "end": 
"2020-09-02 19:07:49.098795", "msg": "non-zero return code", "rc": 127, 
"start": "2020-09-02 19:07:49.091023", "stderr": "sh: 
control.postcodesio.nodejs.sh: No such file or directory", "stderr_lines": 
["sh: control.postcodesio.nodejs.sh: No such file or directory"], "stdout": 
"", "stdout_lines": []}



Any ideas much appreciated.

-- 
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...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/ansible-project/e814918d-97b0-4127-9fcb-bb2e57a6ad44n%40googlegroups.com.


Re: [ansible-project] Error:a bug: 'utf8' codec can't decode byte 0xa0 in position 588

2020-09-02 Thread Dick Visser
Please include the actual text and not some huge yet fuzzy photo.
Also, you still did not include the playbook that triggers this error.
So, send the actual playbook, and the text of the error (just using
"copy/paste" should do).

On Tue, 1 Sep 2020 at 14:25, erdivay singhal  wrote:
>
> Hi stefen
> Please find the attached detail of error
>
>
> On Tue, Sep 1, 2020, 5:45 PM Stefan Hornburg (Racke)  wrote:
>>
>> On 9/1/20 2:12 PM, erdivay singhal wrote:
>> > This is the only error show after running the yaml
>> >
>>
>> So how does your playbook look like? What's the complete output of the task 
>> in error?
>>
>> Regards
>> Racke
>>
>> > On Tue, Sep 1, 2020, 5:26 PM Stefan Hornburg (Racke) > > > wrote:
>> >
>> > On 9/1/20 1:17 PM, erdivay singhal wrote:
>> > > Hi Team,
>> > >  Any idea for the below mentioned error
>> > >
>> > > Error:a bug: 'utf8' codec can't decode byte 0xa0 in position 588
>> >
>> > No idea due to missing context.
>> >
>> > Regards
>> >  Racke
>> >
>> > >
>> > > --
>> > > 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...@googlegroups.com 
>> > 
>> > > > >.
>> > > To view this discussion on the web visit
>> > > 
>> > https://groups.google.com/d/msgid/ansible-project/b92c1fc0-3218-4dfa-9249-3203651f8ef4n%40googlegroups.com
>> > >
>> > 
>> > .
>> >
>> >
>> > --
>> > Ecommerce and Linux consulting + Perl and web application programming.
>> > Debian and Sympa administration. Provisioning with Ansible.
>> >
>> > --
>> > 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...@googlegroups.com 
>> > .
>> > To view this discussion on the web visit
>> > 
>> > https://groups.google.com/d/msgid/ansible-project/f7818af4-f18f-1f2b-220f-4fc005879032%40linuxia.de.
>> >
>> > --
>> > 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...@googlegroups.com 
>> > .
>> > To view this discussion on the web visit
>> > https://groups.google.com/d/msgid/ansible-project/CANR_Rw0tG_qKzDCv82rew2faoVuFx_yzVAwVQE5zvNgP867kmg%40mail.gmail.com
>> > .
>>
>>
>> --
>> Ecommerce and Linux consulting + Perl and web application programming.
>> Debian and Sympa administration. Provisioning with Ansible.
>>
>> --
>> 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...@googlegroups.com.
>> To view this discussion on the web visit 
>> https://groups.google.com/d/msgid/ansible-project/3b688089-abe3-f1e6-27b4-32698423c691%40linuxia.de.
>
> --
> 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...@googlegroups.com.
> To view this discussion on the web visit 
> https://groups.google.com/d/msgid/ansible-project/CANR_Rw11YLtD_7KVviU0djw8%3D-xBx_ySjnP%2B02zSp-4FcqAf5w%40mail.gmail.com.



-- 
Dick Visser
Trust & Identity Service Operations Manager
GÉANT

-- 
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...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/ansible-project/CAL8fbwO-o-wzvb7RzsRY-Z-kpt1QkkWQoM5px09pPucUixYdjw%40mail.gmail.com.


Re: [ansible-project] find_output with filter

2020-09-02 Thread Nagesh sheregar
Thank you so much for the info ..

On Wed, Sep 2, 2020 at 12:35 PM Dick Visser  wrote:

> I would use the json output option of the sos tool and then filter things.
> Manipulating that big block of text will be very cumbersome and fragile.
>
> Fyi this list is not exactly a 'team' but more a collection of individuals
> willing to help.
>
>
>
> On Wed, 2 Sep 2020 at 13:13, Nagesh sheregar  wrote:
>
>> Hi Team,
>>
>> Any help is appreciated?
>>
>> Thanks
>>
>> On Tue, Sep 1, 2020 at 5:32 PM Nagesh sheregar 
>> wrote:
>>
>>> Hi Team,
>>>
>>> i would like to see only GREEN/RED in out put, can you please let me
>>> know how i can filter it?
>>> Playbook:
>>>
>>> - name: sddc health
>>>   command: /opt/vmware/sddc-support/sos --health-check
>>>   register: find_output
>>> - debug:
>>>  var: find_output
>>> =
>>>
>>> Output:
>>>
>>> 
>>>
>>>  SL# |  Area
>>>  |Title| State
>>> |",
>>>
>>> "+-+---+-+---+",
>>> "|  1  |
>>>|Total no. of disks : 9
>>>  | \u001b[1;32mGREEN\u001b[0m |",
>>> "| |
>>>|  vSAN Health Status
>>>  | \u001b[1;32mGREEN\u001b[0m |",
>>> "|  2  |
>>>|Total no. of disks : 9
>>>  | \u001b[1;32mGREEN\u001b[0m |",
>>> "| |
>>>|  vSAN Health Status
>>>  | \u001b[1;32mGREEN\u001b[0m |",
>>> "|  3  |
>>>|Total no. of disks : 9
>>>  | \u001b[1;32mGREEN\u001b[0m |",
>>> "| |
>>>|  vSAN Health Status
>>>  | \u001b[1;32mGREEN\u001b[0m |",
>>> "|  4  |
>>>|Total no. of disks : 9
>>>  | \u001b[1;32mGREEN\u001b[0m |",
>>> "| |
>>>|  vSAN Health Status
>>>  | \u001b[1;32mGREEN\u001b[0m |",
>>> "|  5  |
>>>|Total no. of disks : 9
>>>  | \u001b[1;32mGREEN\u001b[0m |",
>>> "| |
>>>|  vSAN Health Status
>>>  | \u001b[1;32mGREEN\u001b[0m |",
>>> "|  6  |
>>>|Total no. of disks : 9
>>>  | \u001b[1;32mGREEN\u001b[0m |",
>>> "| |
>>>|  vSAN Health Status
>>>  | \u001b[1;32mGREEN\u001b[0m |",
>>> "|  7  |
>>>|Total no. of disks : 9
>>>  | \u001b[1;32mGREEN\u001b[0m |",
>>> "| |
>>>|  vSAN Health Status
>>>  | \u001b[1;32mGREEN\u001b[0m |",
>>> "|  8  |
>>>|Total no. of disks : 9
>>>  | \u001b[1;32mGREEN\u001b[0m |",
>>> "| |
>>>|  vSAN Health Status
>>>  | \u001b[1;32mGREEN\u001b[0m |",
>>> "|  9  |
>>>|  ** Stretched cluster is disabled.
>>>   |   |",
>>> "| |
>>>|  Cluster vSAN Health Status
>>>  | \u001b[1;32mGREEN\u001b[0m |",
>>> "| |
>>>|  ** Deduplication enabled on this cluster.
>>>   |   |",
>>> "| |
>>>|   ** Encryption disabled on this cluster.
>>>  |   |",
>>> "| |
>>>|   ** Compression enabled on this cluster.
>>>  |   |",
>>> "| |
>>>|  Total no. of hosts in cluster : 8
>>>   | \u001b[1;32mGREEN\u001b[0m |",
>>> "|  10 |
>>>|
>>> Node-20a8c662-1bab-43ff-b190-71d6a9c0bc51-NSX-controller-3 |
>>> \u001b[1;32mGREEN\u001b[0m |",
>>> "| |
>>>|centos-6-dHJ8
>>>   | \u001b[1;32mGREEN\u001b[0m |",
>>> "| |
>>>|  WIN2012DTC-64-FxZS
>>>  | \u001b[1;32mGREEN\u001b[0m |",
>>>
>>>
>>>
>>>
>>>
>>>
>>>
>>>
>>>
>>> --
>>>
>>>
>>> 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...@googlegroups.com.
>>>
>>>
>>> To view this discussion on the web visit
>>> https://groups.google.com/d/msgid/ansible-project/f80f2498-1258-4f99-9bf5-f2a0edde706bn%40googlegroups.com
>>> 

Re: [ansible-project] find_output with filter

2020-09-02 Thread Dick Visser
I would use the json output option of the sos tool and then filter things.
Manipulating that big block of text will be very cumbersome and fragile.

Fyi this list is not exactly a 'team' but more a collection of individuals
willing to help.



On Wed, 2 Sep 2020 at 13:13, Nagesh sheregar  wrote:

> Hi Team,
>
> Any help is appreciated?
>
> Thanks
>
> On Tue, Sep 1, 2020 at 5:32 PM Nagesh sheregar 
> wrote:
>
>> Hi Team,
>>
>> i would like to see only GREEN/RED in out put, can you please let me know
>> how i can filter it?
>> Playbook:
>>
>> - name: sddc health
>>   command: /opt/vmware/sddc-support/sos --health-check
>>   register: find_output
>> - debug:
>>  var: find_output
>> =
>>
>> Output:
>>
>> 
>>
>>  SL# |  Area
>>|Title| State |",
>>
>> "+-+---+-+---+",
>> "|  1  |
>>  |Total no. of disks : 9
>>| \u001b[1;32mGREEN\u001b[0m |",
>> "| |
>>  |  vSAN Health Status
>>| \u001b[1;32mGREEN\u001b[0m |",
>> "|  2  |
>>  |Total no. of disks : 9
>>| \u001b[1;32mGREEN\u001b[0m |",
>> "| |
>>  |  vSAN Health Status
>>| \u001b[1;32mGREEN\u001b[0m |",
>> "|  3  |
>>  |Total no. of disks : 9
>>| \u001b[1;32mGREEN\u001b[0m |",
>> "| |
>>  |  vSAN Health Status
>>| \u001b[1;32mGREEN\u001b[0m |",
>> "|  4  |
>>  |Total no. of disks : 9
>>| \u001b[1;32mGREEN\u001b[0m |",
>> "| |
>>  |  vSAN Health Status
>>| \u001b[1;32mGREEN\u001b[0m |",
>> "|  5  |
>>  |Total no. of disks : 9
>>| \u001b[1;32mGREEN\u001b[0m |",
>> "| |
>>  |  vSAN Health Status
>>| \u001b[1;32mGREEN\u001b[0m |",
>> "|  6  |
>>  |Total no. of disks : 9
>>| \u001b[1;32mGREEN\u001b[0m |",
>> "| |
>>  |  vSAN Health Status
>>| \u001b[1;32mGREEN\u001b[0m |",
>> "|  7  |
>>  |Total no. of disks : 9
>>| \u001b[1;32mGREEN\u001b[0m |",
>> "| |
>>  |  vSAN Health Status
>>| \u001b[1;32mGREEN\u001b[0m |",
>> "|  8  |
>>  |Total no. of disks : 9
>>| \u001b[1;32mGREEN\u001b[0m |",
>> "| |
>>  |  vSAN Health Status
>>| \u001b[1;32mGREEN\u001b[0m |",
>> "|  9  |
>>  |  ** Stretched cluster is disabled.
>> |   |",
>> "| |
>>  |  Cluster vSAN Health Status
>>| \u001b[1;32mGREEN\u001b[0m |",
>> "| |
>>  |  ** Deduplication enabled on this cluster.
>> |   |",
>> "| |
>>  |   ** Encryption disabled on this cluster.
>>|   |",
>> "| |
>>  |   ** Compression enabled on this cluster.
>>|   |",
>> "| |
>>  |  Total no. of hosts in cluster : 8
>> | \u001b[1;32mGREEN\u001b[0m |",
>> "|  10 |
>>  |
>> Node-20a8c662-1bab-43ff-b190-71d6a9c0bc51-NSX-controller-3 |
>> \u001b[1;32mGREEN\u001b[0m |",
>> "| |
>>  |centos-6-dHJ8
>> | \u001b[1;32mGREEN\u001b[0m |",
>> "| |
>>  |  WIN2012DTC-64-FxZS
>>| \u001b[1;32mGREEN\u001b[0m |",
>>
>>
>>
>>
>>
>>
>>
>>
>>
>> --
>>
>>
>> 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...@googlegroups.com.
>>
>>
>> To view this discussion on the web visit
>> https://groups.google.com/d/msgid/ansible-project/f80f2498-1258-4f99-9bf5-f2a0edde706bn%40googlegroups.com
>> 
>> .
>>
>>
>>
>
>
>
>
>
> --
>
> 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 

Re: [ansible-project] Using the filter_plugins in conditional when

2020-09-02 Thread Dick Visser
Isn't this what systemd is supposed to be for?
If you deploy a proper systemd unit, you can use the service module.

On Wed, 2 Sep 2020 at 15:43, Rafael Tomelin 
wrote:

> Hi dear,
>
> I created the filter_plugin that check if running process and return true
> or false. This is an example:
>
> process_name|get_processes
>
> I want to create this task:
>
> *- name: start service*
> *  shell: /usr/local/bin/my_script*
> *  when: process_name|get_processes is false*
>
> But it seems to me that the conditional does not accept filter_plugin.
>
> --
> Atenciosamente,
>
> Rafael Tomelin
> Tel.: 51-984104084
> Skype: rafael.tomelin
>
> LPI ID: LPI000191271
> Red Hat Certified Engineer
> Puppet Professional 2017 Certification
>
>
>
>
>
>
>
>
> --
>
>
> 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...@googlegroups.com.
>
>
> To view this discussion on the web visit
> https://groups.google.com/d/msgid/ansible-project/CAGEUqbDLJ%2BqXtCOvrPELFQA9OeoSG7Q-p7kZbAdW0yvVRuftKw%40mail.gmail.com
> 
> .
>
>
> --
Sent from a mobile device - please excuse the brevity, spelling and
punctuation.

-- 
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...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/ansible-project/CAL8fbwOfjPKaKBtujceM1WpvL9pQAJ0UPVZFQc-d3jzOdyx2LQ%40mail.gmail.com.


Re: [ansible-project] Getting syntax error

2020-09-02 Thread 'Ramu Mathi' via Ansible Project
Any update on this? Please let me know. I need your help.

On Wed, Sep 2, 2020 at 10:13 AM Ramu Mathi  wrote:

> Singh, We need roles here and we are calling the same way for others and
> they are working well.  Only for this host configuration I am getting that
> error. Can we deep debug on this?
>
> On Wed, Sep 2, 2020 at 1:03 AM Kundan Singh 
> wrote:
>
>> As per my understanding roles will not require and specific tags
>>
>> -  hosts: "{{ groups['all'][0] }}"
>>gather_facts: no
>> become: true
>>
>> vars_files:
>>  -
>>  roles:
>>  -   abc
>>   Or
>>   - "{{ and role name }}"
>>
>> On Tue, Sep 1, 2020, 9:02 PM 'Ramu Mathi' via Ansible Project <
>> ansible-project@googlegroups.com> wrote:
>>
>>> Hi Singh, This is my configuration and it invokes the below tasks. -
>>> hosts: "{{ groups['all'][0] }}"
>>> gather_facts: no
>>> become: true
>>> vars_files:
>>> -
>>> roles:
>>> - { role: */*, tags: ['**'] }
>>> ---
>>> - name: add vhosts
>>> shell: "docker exec rmq-ha rabbitmqctl add_vhost {{ item.name }}"
>>> with_items: "{{ *** }}"
>>> ignore_errors: true
>>> - name: add users
>>> shell: "docker exec rmq-ha rabbitmqctl add_user {{ item.name }} {{
>>> item.password }}"
>>> with_items: "{{ *** }}"
>>> ignore_errors: true
>>> tags:
>>> - ***
>>> - name: change users passwords
>>> shell: "docker exec rmq-ha rabbitmqctl change_password {{ item.name }}
>>> {{ item.password }}"
>>> with_items: "{{ *** }}"
>>> ignore_errors: true
>>> tags:
>>> - ***
>>> - name: add user tags
>>> shell: "docker exec rmq-ha rabbitmqctl set_user_tags {{ item.name }} {{
>>> item.tags }}"
>>> with_items: "{{ *** }}"
>>> ignore_errors: true
>>> tags:
>>> - *** Now I am getting that error, where we need to add that double
>>> quote? Thanks, Ramu.
>>>
>>> On Tue, Sep 1, 2020 at 7:53 PM Kundan Singh 
>>> wrote:
>>>
 Hi ,

 There is a syntax issue in the jinja2 template
 When you are defining hosts there should be space in variable mention
 in the line

 Synatx should appear like below

 hosts: "{{ abc }}"


 Regards
 Kundan singh

 On Tue, Sep 1, 2020, 3:13 PM 'Ramu Mathi' via Ansible Project <
 ansible-project@googlegroups.com> wrote:

> I am getting the following the error with my config
>
>
> ERROR! The field 'hosts' has an invalid value, which includes an
> undefined variable. The error was: list object has no element 0
>
>
> The error appears to be in
> '/Users/ramumathi/Desktop/workspace/RMQ/ansible-rmq-ha/playbook.yml': line
> 91, column 3, but may
>
> be elsewhere in the file depending on the exact syntax problem.
>
>
> The offending line appears to be:
>
>
>
> - hosts: "{{ groups['all'][0] }}"
>
>   ^ here
>
> We could be wrong, but this one looks like it might be an issue with
>
> missing quotes. Always quote template expression brackets when they
>
> start a value. For instance:
>
>
> with_items:
>
>   - {{ foo }}
>
>
> Should be written as:
>
>
> with_items:
>
>   - "{{ foo }}"
>
>
>  ansible-playbook --version
>
> ansible-playbook 2.8.1
>
>   python version = 2.7.16 (default, Dec 13 2019, 18:00:32) [GCC 4.2.1
> Compatible Apple LLVM 11.0.0 (clang-1100.0.32.4) (-macos10.15-objc-s
>
> Can you please let me know why I am getting this error.
>
> Thanks,
>
> Ramu.
>
> --
> 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...@googlegroups.com.
> To view this discussion on the web visit
> https://groups.google.com/d/msgid/ansible-project/37056e7f-6ece-4f17-b633-23efebb8b80fn%40googlegroups.com
> 
> .
>
 --
 You received this message because you are subscribed to a topic in the
 Google Groups "Ansible Project" group.
 To unsubscribe from this topic, visit
 https://groups.google.com/d/topic/ansible-project/r-WAba-9WI0/unsubscribe
 .
 To unsubscribe from this group and all its topics, send an email to
 ansible-project+unsubscr...@googlegroups.com.
 To view this discussion on the web visit
 https://groups.google.com/d/msgid/ansible-project/CADGcVU2SfQO%3D-7g8K_k-zARf%3DkgEUMfhHWywu%3DcrHFRtCPhJHA%40mail.gmail.com
 
 .

>>> --
>>> You received this message because you are 

Re: [ansible-project] Generate HTML Table from Ansible Inventory File

2020-09-02 Thread Vladimir Botka
On Wed, 2 Sep 2020 07:17:42 -0700 (PDT)
Xinhuan Zheng  wrote:

> ... if I want to reference all hosts in a 
> group, should I use
>
> {% for host in groups[group] %}

If "group" is the name of the group then use

  {% for host in groups['group'] %}

or, simply

  {% for host in groups.group %}

If "group" is the variable with the name of the group use

  {% for host in groups[group] %}


-- 
Vladimir Botka

-- 
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...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/ansible-project/20200902174531.1626a673%40gmail.com.


pgpSPtXVVOIBM.pgp
Description: OpenPGP digital signature


[ansible-project] Re: unzip to unarchive

2020-09-02 Thread Nuno Costa
I'm using something like below but I had to add *ignore_errors**: yes* due 
to what I believe is a bug in ansible and/or unarchive module.
The task always fail but the files are extracted.

Got this workaround from 
https://github.com/ansible/ansible/issues/27081#issuecomment-595842668

   - name: Unzip core plugins from war file
  unarchive:
remote_src: true
src: "/home/user/gerrit-war/gerrit-3.2.3.war"
extra_opts:
  - -j
  - "/home/user/gerrit-war/gerrit-3.2.3.war"
  - "WEB-INF/plugins/{{ item }}.jar"
dest: "/home/user"
  loop:
- replication
- gitiles
  ignore_errors: yes 


On Monday, 31 August 2020 at 22:48:31 UTC+1 lpesc...@google.com wrote:

> Bump - anyone?
>
> On Friday, August 28, 2020 at 9:42:13 AM UTC-7 lpesc...@google.com wrote:
>
>> I'm also curious about how the -o and -d switches in the original 
>> playbook relate to the new.
>>
>> On Friday, August 28, 2020 at 9:41:24 AM UTC-7 lpesc...@google.com wrote:
>>
>>> Hi all, 
>>> I want to change this to unarchive:
>>>
>>> - name: unpack-protos-bin
>>>   shell: unzip -o /root/.ansible-management/file.zip -d /usr/local 
>>> bin/protoc
>>>   args:
>>> executable: /bin/bash
>>>   notify:
>>> - unpack-proto-includes
>>>
>>> - name: unpack-proto-includes
>>>   shell: unzip -o /root/.ansible-management/file.zip -d /usr/local 
>>> include/*
>>>   args:
>>> executable: /bin/bash
>>>
>>>
>>> This is what I have surmounted, but not sure if it's correct:
>>>
>>> - name: unpack-protos-bin
>>>   unarchive:
>>> src: file.zip
>>> dest: /usr/local/bin/protoc
>>>   notify:
>>> - unpack-proto-includes
>>>
>>> - name: unpack-proto-includes
>>>   unarchive:
>>> src: 
>>> https://github.com/google/protobuf/releases/download/v3.4.0/file.zip
>>> dest: /usr/local/include/*
>>>
>>> Can anyone tell me if I am correct, and if not, how to resolve?
>>>
>>>
>>>

-- 
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...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/ansible-project/923b3d11-ce53-4317-82c4-db47d48fd179n%40googlegroups.com.


Re: [ansible-project] copy file to host not in inventory

2020-09-02 Thread Ankit Vashistha
I am not sure if i clearly understood your question but, you might look
into this:
https://docs.ansible.com/ansible/latest/modules/add_host_module.html

*Regards,*
*Ankit*


On Tue, Sep 1, 2020 at 9:25 PM william...@gmail.com <
william.doss...@gmail.com> wrote:

> Hi, sorry, I can't quite get my head around the last bit of my playbook.
>
> I have a playbook that is doing ssh key rotations - it is pretty much all
> working other than once it has generated the keys and used authorized_keys
> module to put them on the hosts in the inventory, I want to copy the keys
> back to my workstation.  Then it deletes the keys to cleanup.  I use
> delegate_to and run_once when creating the keys, but how do I copy the keys
> to my workstation which is not in my inventory - I am using dynamic
> inventories in AWX... this isn't something I have run into before, I will
> have to use a command worst case I guess, but welcome any alternative
> suggestions.
>
> thanks
> Bill
>
> --
> 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...@googlegroups.com.
> To view this discussion on the web visit
> https://groups.google.com/d/msgid/ansible-project/eb6c28eb-114b-445b-bd74-9359d1e78673n%40googlegroups.com
> 
> .
>

-- 
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...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/ansible-project/CACecUhuHUKuthtK3rwr8-uM%2BB5yq05eBq8ka%3Dg%2B32ER1Q7gKyg%40mail.gmail.com.


[ansible-project] Using the filter_plugins in conditional when

2020-09-02 Thread Rafael Tomelin
Hi dear,

I created the filter_plugin that check if running process and return true
or false. This is an example:

process_name|get_processes

I want to create this task:

*- name: start service*
*  shell: /usr/local/bin/my_script*
*  when: process_name|get_processes is false*

But it seems to me that the conditional does not accept filter_plugin.

-- 
Atenciosamente,

Rafael Tomelin
Tel.: 51-984104084
Skype: rafael.tomelin

LPI ID: LPI000191271
Red Hat Certified Engineer
Puppet Professional 2017 Certification

-- 
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...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/ansible-project/CAGEUqbDLJ%2BqXtCOvrPELFQA9OeoSG7Q-p7kZbAdW0yvVRuftKw%40mail.gmail.com.


Re: [ansible-project] Deploying a application using WAR file on Websphere

2020-09-02 Thread Rachna Dodia
Thanks for the response.

@Abhijeet , the example which you have shared have already available 
modules for JBOSS deployment. 

Where I cannot see or map any module as such for application deployment on 
Websphere.

Thanks,
Rachna Dodia 

On Wednesday, September 2, 2020 at 4:48:19 PM UTC+5:30 Abhijeet Kasurde 
wrote:

> Check examples like 
>
>
>1. 
>
> https://github.com/ansible/ansible-examples/blob/bedca7401f01411ec9d1b9231f5dc4a19ba12960/tomcat-memcached-failover/roles/tomcat/tasks/main.yml
>2. 
>
> https://github.com/ansible/ansible-examples/blob/59484f4fbfaa8d2c3938661c296ed6c9ae27d956/jboss-standalone/roles/java-app/tasks/main.yml
>
>
> On Wed, Sep 2, 2020 at 4:46 PM Avinash Jadhav  
> wrote:
>
>> Hi Rachna,
>>
>> Please find below playbook for  war file deployment you need to changes 
>> your sources WAR and destination for Websphere 
>>
>> Thank you 
>> Avinash 
>>
>> 
>> - hosts: tomcatServer
>>   vars:
>>   - warName: helloworld.war
>>   - warRemotePath: /path/to/put/war
>>
>>   tasks:
>>   - name: Download WAR to server
>> synchronize: src={{ warLocalPath }}/{{ warName }} dest={{ 
>> warRemotePath }}/{{ warName }}
>>
>>   - name: Unzip WAR file
>> unarchive: src={{ warRemotePath }}/{{ warName }} 
>> dest=/var/lib/tomcat7/webapps/ROOT/ copy=no mode=0755 owner=tomcat7 
>> group=tomcat7
>> notify:
>> - Restart tomcat7
>>
>>   - name: Delete remote war file
>> file: path={{ warRemotePath }}/{{ warName }} state=absent
>>
>>   handlers:
>> - name: Restart tomcat7
>>   service: name=tomcat7 state=restarted
>>
>> On Wed, 2 Sep 2020 at 16:31, Rachna Dodia  wrote:
>>
>>> Need your inputs on how to go forward with deploying application using 
>>> WAR file on Websphere using Ansible.
>>>
>>> I cannot see any modules or playbooks related to the same. 
>>>
>>> Looking for any suggestion or approach how to take this forward.
>>>
>>> Thanks,
>>> Rachna Dodia
>>>
>>> -- 
>>> 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-proje...@googlegroups.com.
>>> To view this discussion on the web visit 
>>> https://groups.google.com/d/msgid/ansible-project/c58bfb7b-fcde-4ab5-ab80-4049f9ee0a3dn%40googlegroups.com
>>>  
>>> 
>>> .
>>>
>> -- 
>> 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-proje...@googlegroups.com.
>>
> To view this discussion on the web visit 
>> https://groups.google.com/d/msgid/ansible-project/CABAvFDM%2B7J7z-T-cLdmE%2BV-A9eXtCX6kuVPtc1PctNahpgTahA%40mail.gmail.com
>>  
>> 
>> .
>>
>
>
> -- 
> Thanks,
> Abhijeet Kasurde
>

-- 
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...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/ansible-project/933190c7-cd6d-440e-8050-80195362ccacn%40googlegroups.com.


Re: [ansible-project] Deploying a application using WAR file on Websphere

2020-09-02 Thread Abhijeet Kasurde
Check examples like


   1.
   
https://github.com/ansible/ansible-examples/blob/bedca7401f01411ec9d1b9231f5dc4a19ba12960/tomcat-memcached-failover/roles/tomcat/tasks/main.yml
   2.
   
https://github.com/ansible/ansible-examples/blob/59484f4fbfaa8d2c3938661c296ed6c9ae27d956/jboss-standalone/roles/java-app/tasks/main.yml


On Wed, Sep 2, 2020 at 4:46 PM Avinash Jadhav 
wrote:

> Hi Rachna,
>
> Please find below playbook for  war file deployment you need to changes
> your sources WAR and destination for Websphere
>
> Thank you
> Avinash
>
> 
> - hosts: tomcatServer
>   vars:
>   - warName: helloworld.war
>   - warRemotePath: /path/to/put/war
>
>   tasks:
>   - name: Download WAR to server
> synchronize: src={{ warLocalPath }}/{{ warName }} dest={{
> warRemotePath }}/{{ warName }}
>
>   - name: Unzip WAR file
> unarchive: src={{ warRemotePath }}/{{ warName }}
> dest=/var/lib/tomcat7/webapps/ROOT/ copy=no mode=0755 owner=tomcat7
> group=tomcat7
> notify:
> - Restart tomcat7
>
>   - name: Delete remote war file
> file: path={{ warRemotePath }}/{{ warName }} state=absent
>
>   handlers:
> - name: Restart tomcat7
>   service: name=tomcat7 state=restarted
>
> On Wed, 2 Sep 2020 at 16:31, Rachna Dodia  wrote:
>
>> Need your inputs on how to go forward with deploying application using
>> WAR file on Websphere using Ansible.
>>
>> I cannot see any modules or playbooks related to the same.
>>
>> Looking for any suggestion or approach how to take this forward.
>>
>> Thanks,
>> Rachna Dodia
>>
>> --
>> 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...@googlegroups.com.
>> To view this discussion on the web visit
>> https://groups.google.com/d/msgid/ansible-project/c58bfb7b-fcde-4ab5-ab80-4049f9ee0a3dn%40googlegroups.com
>> 
>> .
>>
> --
> 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...@googlegroups.com.
> To view this discussion on the web visit
> https://groups.google.com/d/msgid/ansible-project/CABAvFDM%2B7J7z-T-cLdmE%2BV-A9eXtCX6kuVPtc1PctNahpgTahA%40mail.gmail.com
> 
> .
>


-- 
Thanks,
Abhijeet Kasurde

-- 
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...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/ansible-project/CAFwWkHra-k7zoUJHDBgnKwEe7Yeybb5niG-HHmDYADWhvpajWg%40mail.gmail.com.


Re: [ansible-project] Deploying a application using WAR file on Websphere

2020-09-02 Thread Avinash Jadhav
Hi Rachna,

Please find below playbook for  war file deployment you need to changes
your sources WAR and destination for Websphere

Thank you
Avinash


- hosts: tomcatServer
  vars:
  - warName: helloworld.war
  - warRemotePath: /path/to/put/war

  tasks:
  - name: Download WAR to server
synchronize: src={{ warLocalPath }}/{{ warName }} dest={{ warRemotePath
}}/{{ warName }}

  - name: Unzip WAR file
unarchive: src={{ warRemotePath }}/{{ warName }}
dest=/var/lib/tomcat7/webapps/ROOT/ copy=no mode=0755 owner=tomcat7
group=tomcat7
notify:
- Restart tomcat7

  - name: Delete remote war file
file: path={{ warRemotePath }}/{{ warName }} state=absent

  handlers:
- name: Restart tomcat7
  service: name=tomcat7 state=restarted

On Wed, 2 Sep 2020 at 16:31, Rachna Dodia  wrote:

> Need your inputs on how to go forward with deploying application using WAR
> file on Websphere using Ansible.
>
> I cannot see any modules or playbooks related to the same.
>
> Looking for any suggestion or approach how to take this forward.
>
> Thanks,
> Rachna Dodia
>
> --
> 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...@googlegroups.com.
> To view this discussion on the web visit
> https://groups.google.com/d/msgid/ansible-project/c58bfb7b-fcde-4ab5-ab80-4049f9ee0a3dn%40googlegroups.com
> 
> .
>

-- 
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...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/ansible-project/CABAvFDM%2B7J7z-T-cLdmE%2BV-A9eXtCX6kuVPtc1PctNahpgTahA%40mail.gmail.com.


Re: [ansible-project] find_output with filter

2020-09-02 Thread Nagesh sheregar
Hi Team,

Any help is appreciated?

Thanks

On Tue, Sep 1, 2020 at 5:32 PM Nagesh sheregar  wrote:

> Hi Team,
>
> i would like to see only GREEN/RED in out put, can you please let me know
> how i can filter it?
> Playbook:
>
> - name: sddc health
>   command: /opt/vmware/sddc-support/sos --health-check
>   register: find_output
> - debug:
>  var: find_output
> =
>
> Output:
>
> 
>
>  SL# |  Area
>|Title| State |",
>
> "+-+---+-+---+",
> "|  1  |
>  |Total no. of disks : 9
>| \u001b[1;32mGREEN\u001b[0m |",
> "| |
>  |  vSAN Health Status
>| \u001b[1;32mGREEN\u001b[0m |",
> "|  2  |
>  |Total no. of disks : 9
>| \u001b[1;32mGREEN\u001b[0m |",
> "| |
>  |  vSAN Health Status
>| \u001b[1;32mGREEN\u001b[0m |",
> "|  3  |
>  |Total no. of disks : 9
>| \u001b[1;32mGREEN\u001b[0m |",
> "| |
>  |  vSAN Health Status
>| \u001b[1;32mGREEN\u001b[0m |",
> "|  4  |
>  |Total no. of disks : 9
>| \u001b[1;32mGREEN\u001b[0m |",
> "| |
>  |  vSAN Health Status
>| \u001b[1;32mGREEN\u001b[0m |",
> "|  5  |
>  |Total no. of disks : 9
>| \u001b[1;32mGREEN\u001b[0m |",
> "| |
>  |  vSAN Health Status
>| \u001b[1;32mGREEN\u001b[0m |",
> "|  6  |
>  |Total no. of disks : 9
>| \u001b[1;32mGREEN\u001b[0m |",
> "| |
>  |  vSAN Health Status
>| \u001b[1;32mGREEN\u001b[0m |",
> "|  7  |
>  |Total no. of disks : 9
>| \u001b[1;32mGREEN\u001b[0m |",
> "| |
>  |  vSAN Health Status
>| \u001b[1;32mGREEN\u001b[0m |",
> "|  8  |
>  |Total no. of disks : 9
>| \u001b[1;32mGREEN\u001b[0m |",
> "| |
>  |  vSAN Health Status
>| \u001b[1;32mGREEN\u001b[0m |",
> "|  9  |
>  |  ** Stretched cluster is disabled.
> |   |",
> "| |
>  |  Cluster vSAN Health Status
>| \u001b[1;32mGREEN\u001b[0m |",
> "| |
>  |  ** Deduplication enabled on this cluster.
> |   |",
> "| |
>  |   ** Encryption disabled on this cluster.
>|   |",
> "| |
>  |   ** Compression enabled on this cluster.
>|   |",
> "| |
>  |  Total no. of hosts in cluster : 8
> | \u001b[1;32mGREEN\u001b[0m |",
> "|  10 |
>  |
> Node-20a8c662-1bab-43ff-b190-71d6a9c0bc51-NSX-controller-3 |
> \u001b[1;32mGREEN\u001b[0m |",
> "| |
>  |centos-6-dHJ8
> | \u001b[1;32mGREEN\u001b[0m |",
> "| |
>  |  WIN2012DTC-64-FxZS
>| \u001b[1;32mGREEN\u001b[0m |",
>
>
>
>
>
>
>
>
>
> --
>
>
> 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...@googlegroups.com.
>
>
> To view this discussion on the web visit
> https://groups.google.com/d/msgid/ansible-project/f80f2498-1258-4f99-9bf5-f2a0edde706bn%40googlegroups.com
> 
> .
>
>
>

-- 
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...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/ansible-project/CAFu5ZNxU_zNEdZuC1J9X369VQJ7NMROn8MpDFJzMAGFbcYsRFg%40mail.gmail.com.


[ansible-project] Deploying a application using WAR file on Websphere

2020-09-02 Thread Rachna Dodia
Need your inputs on how to go forward with deploying application using WAR 
file on Websphere using Ansible.

I cannot see any modules or playbooks related to the same. 

Looking for any suggestion or approach how to take this forward.

Thanks,
Rachna Dodia

-- 
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...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/ansible-project/c58bfb7b-fcde-4ab5-ab80-4049f9ee0a3dn%40googlegroups.com.


[ansible-project] Deploying application using WAR on Websphere using Ansible

2020-09-02 Thread Rachna Dodia
Hi Team

Need your inputs on how to go forward with deploying application using WAR 
file on Websphere using Ansible.

I cannot see any modules or playbooks related to the same. 

Looking for any suggestion or approach how to take this forward.

Thanks,
Rachna Dodia

-- 
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...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/ansible-project/30d9b01d-5699-4e44-9283-656e4d345797n%40googlegroups.com.


Re: [ansible-project] Permission issue with become

2020-09-02 Thread Dick Visser
You're trying to use /usr/sbin as a command, which won't work as this
is a directory.
Remove the 'args' stanza and instead use the full path to the shell
command you want to run:

  tasks:
  - name: Update the packages using uptrack
 shell: '/usr/sbin/uptrack-upgrade -y'

On Tue, 1 Sep 2020 at 23:55, maheshn...@gmail.com
 wrote:
>
> Having the same issue here: Any help is appreciated.
> Using
> ansible --version
> ansible 2.5.2
> config file = /etc/ansible/ansible.cfg
> python version = 2.6.6
>
> site.yml
>
> - name: Live patch
>   hosts: all
>   become: yes
>
>   tasks:
>   - name: Update the packages using uptrack
>  shell: 'uptrack-upgrade -y'
>   args:
>executable: /usr/sbin
> ERROR:
> fatal: [10.0.0.1]: FAILED! => {"changed": false, "cmd": "/usr/sbin -c 
> 'uptrack-upgrade -y'", "msg": "[Errno 13] Permission denied", "rc": 13}
>
> --
> 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...@googlegroups.com.
> To view this discussion on the web visit 
> https://groups.google.com/d/msgid/ansible-project/c25c6cba-ffa3-4268-9058-952db53f5866n%40googlegroups.com.



-- 
Dick Visser
Trust & Identity Service Operations Manager
GÉANT

-- 
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...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/ansible-project/CAL8fbwOQj70atNbmgo1eGC6phcriAEN0v8-dS%2BHBAqONEe4SYw%40mail.gmail.com.


Re: [ansible-project] Host SSH key not recognized when trying to SSH into remote repository using Ansible playbook

2020-09-02 Thread Dick Visser
You need to give more info. Playbooks, inventory, what are you trying
to achieve, etc.

On Tue, 1 Sep 2020 at 23:48, Erick Sun  wrote:
>
> Host SSH key not recognized when trying to SSH into remote repository using 
> Ansible playbook. Remote repository was verified to have the correct SSH key 
> from host, but still wouldn't recognize host when trying to clone from the 
> repository. Ran Ansible on 15 hosts, 13 were successful, 1 failed to clone 
> from remote repo even though they were configured the same. Here is the 
> actual error received. Can anyone help, please? Thx
>
> fatal: [Host]: FAILED! => {"changed": false, "cmd": "/usr/bin/git clone 
> --origin origin 'ssh:' /local_path", "msg": "FIPS mode 
> initialized\r\nDisabling GSSAPIKeyExchange. Not usable in FIPS 
> mode\r\nPermission denied (publickey).\r\nfatal: Could not read from remote 
> repository.\n\nPlease make sure you have the correct access rights\nand the 
> repository exists.", "rc": 128, "stderr": "FIPS mode initialized\r\nDisabling 
> GSSAPIKeyExchange. Not usable in FIPS mode\r\nPermission denied (public 
> key).\r\nfatal: Could not read from remote repository.\n\nPlease make sure 
> you have the corr ect access rights\nand the repository exists.\n", 
> "stderr_lines": ["FIPS mode initialized", "Disabling GSSAPIKeyExchange. Not 
> usable in FIPS mode", "Permission denied (publickey).", "fatal: Could not 
> read from remote repository.", "", "Please make sure you have the correct 
> access rights", "and the repository exists."], "stdout": "Cloning into 
> '/local_path'...\n", "stdout_lines": ["Cloning into '/local_path'..."]}
>
> --
> 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...@googlegroups.com.
> To view this discussion on the web visit 
> https://groups.google.com/d/msgid/ansible-project/e84682be-85ac-47b8-8c80-661de0f5dbc6n%40googlegroups.com.



-- 
Dick Visser
Trust & Identity Service Operations Manager
GÉANT

-- 
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...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/ansible-project/CAL8fbwN%3D-00zXZh5cuZtcdPVK5Xw_YH-oN6QFv3PLKZqVoWtSA%40mail.gmail.com.


Re: [ansible-project] Copy condition based on presence in playbook templates folder

2020-09-02 Thread LUCA CARANGELO
Hi Vladimir,

I'm going to test it immediately !

Thank you very much , I really appreciate it.

Il giorno mar 1 set 2020 alle ore 19:12 Vladimir Botka 
ha scritto:

> On Tue, 1 Sep 2020 09:21:06 -0700 (PDT)
> LUCA CARANGELO  wrote:
>
> > if in my playbook tamplates folder there is a file named :
> > configuration--HOST001
> > then copy module with :
> > src : "./templates/configuration--{{ inventory_hostname }}"
> > dst: "/tmp/
> >
> > if ./templates/configuration--HOST001 does not exists
> > then copy module with :
> > src : "./templates/configuration"
> > dst: "/tmp/
>
> Use "first_found". For example
>
> https://docs.ansible.com/ansible/latest/plugins/lookup/first_found.html#first-found-return-first-file-found-from-list
>
>   - copy:
>   src: "{{ lookup('first_found', params) }}"
>   dest: /tmp
> vars:
>   params:
> files:
>   - "configuration--{{ inventory_hostname }}"
>   - configuration
> paths:
>   - "{{ playbook_dir }}/templates"
>
> --
> Vladimir Botka
>


-- 

[image: Sirti S.p.a.]

*Luca Carangelo*

*System Management Manager*
IT Office dept.
Sirti S.p.A.

p:+39 02 9588 6929 | m:+39 335 5909774 | e:l.carang...@sirti.it | w:
www.sirti.it | a:Via Stamira d'Ancona 9, 20127 Milano

-- 







 




 


 







Sirti Società per Azioni, 
con sede legale in Milano, via Stamira d'Ancona n. 9, società con Socio 
unico PS Reti S.p.A. Capitale Sociale Euro 42.040.523 interamente versato - 
Codice Fiscale, Partita IVA e Iscrizione Registro delle Imprese di Milano: 
04596040966


*NOTA DI RISERVATEZZA*
*Questo messaggio e i suoi allegati 
sono destinati esclusivamente alle persone in indirizzo e può contenere 
informazioni riservate. Se avete ricevuto il messaggio per errore, vi 
informiamo che qualsiasi utilizzo dei contenuti della presente è 
assolutamente vietato. Vi invitiamo a rispedire immediatamente la mail al 
mittente e a distruggere il messaggio. Per qualsiasi dubbio, vi invitiamo a 
contattarci rispondendo a webmaster_si...@sirti.it 
*
*      Grazie   www.sirti.it 
*

*
*
*CONFIDENTIALITY NOTICE*
*This message and its 
attachments are addressed solely to the persons above and may contain 
confidential information. If you have received the message in error, be 
informed that any use of the content hereof is prohibited. Please return it 
immediately to the sender and delete the message. Should you have any 
questions, please contact us by replying to webmaster_si...@sirti.it 
*
*      Thank you   www.sirti.it 
*

-- 
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...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/ansible-project/CANOK%3DbFHHRujxBa9p2CjmE52%3DK7W%3D6gawEcKCGRzK7N5E_XQVQ%40mail.gmail.com.


[ansible-project] Ansible 2.10.0 beta 1

2020-09-02 Thread Toshio Kuratomi
Hi all-

For all those wanting to test the next version of Ansible, we're happy
to announce that Ansible 2.10.0 beta1 is now available on PyPI!

Ansible 2.10.0b1 pulls in the ansible-base-2.10.1 (presently rc2)
package via a dependency and includes a range of Ansible Collections.
The Ansible 2.10 PyPI packages provide similar functionality to
Ansible 2.9 and earlier versions, but from multiple sources. The
included Ansible Collections are maintained by a host of open source
contributors who want to add to what ansible-base has to offer.

For an overview of "Ansible Collections" and the differences between
`ansible-base` and `ansible`  please see
https://github.com/ansible-collections/overview/blob/master/README.rst

We need your help
-

This new `ansible` package *should* be a drop-in replacement for
Ansible 2.9. The roles and playbooks that you currently use should
work out of the box with ansible-2.10.0 beta1.

Please let us know if:

* Your playbooks don't work
* There are any installation issues
* Whether the collections are found OK
* If the updated and new modules in the collections work

How to get it
-

Due to a limitation in pip, you need to uninstall Ansible 2.9 (or
earlier) before installing the 2.10 version:

$ pip uninstall ansible
$ pip install ansible==2.10.0b1 --user

The tar.gz of the release can be found here:

* Ansible 2.10.0b1
  https://pypi.python.org/packages/source/a/ansible/ansible-2.10.0b1.tar.gz
  SHA256: 081c1b1ea95a0b67f8bf1e5c3c45b8e8dd8bafd1f8d05838f96239da3496ce8f


What's new in Ansible 2.10.0b1
--

* Collections which have opted into being a part of the Ansible-2.10.0
unified changelog will have an entry on this page:
https://github.com/ansible-community/ansible-build-data/blob/main/2.10/CHANGELOG-v2.10.rst

* For other collections, consult the list of included collections in
the link below and check their entry on https://galaxy.ansible.com for
information about their changes.

* List of collections included in the 2.10.0b1 release:
  * 
https://github.com/ansible-community/ansible-build-data/blob/2.10.0b1/2.10/ansible-2.10.0b1.deps
  * You can find more information for those on
https://galaxy.ansible.com/.  For instance, the community.crypto
collection listed in the ansible-2.10.0b1.deps file has a galaxy page
here at https://galaxy.ansible.com/community/crypto/

* Changelog for ansible-base-2.10.1 which this release of ansible installs:
  
https://github.com/ansible/ansible/blob/stable-2.10/changelogs/CHANGELOG-v2.10.rst


Caveats and known bugs
--

* The individual collections that make up the ansible-2.10.0 package
can be viewed independently.  However, they aren't currently listed by
ansible-galaxy.  A workaround for this is to explicitly specify where
ansible has installed the collections::

COLLECTION_INSTALL=$(python -c 'import ansible, os.path ;
print("%s/../ansible_collections" %
os.path.dirname(ansible.__file__))') ansible-galaxy collection list -p
"$COLLECTION_INSTALL"

  * A fix has been proposed but was not be merged for 2.10.0. This is
being tracked in this bug report:
https://github.com/ansible/ansible/issues/70147

* Due to a limitation in pip, you cannot `pip install --upgrade` from
ansible-2.9 or earlier to ansible-2.10 or higher.  Instead, you must
explicitly `pip uninstall ansible` before pip installing the new
version.  The install of the ansible package has been modified to warn
you if you attempt to upgrade via pip with instructions to uninstall
first.


What's the schedule for the rest of the 2.10.0 release cycle?
-

ansible-2.10.0rc1 is due to be released on 2020-09-10
ansible-2.10.0 final is due out on 2020-09-22

The ansible-2.10 roadmap reflects these dates:
https://docs.ansible.com/ansible/devel/roadmap/COLLECTIONS_2_10.html

Porting Help


There's a unified porting guide for collections which have opted-in.
You can find that at:
https://github.com/ansible/ansible/blob/devel/docs/docsite/rst/porting_guides/porting_guide_2.10.rst

If you encounter any bugs, please report them.  We're putting together
a draft document which includes where to report bugs on various parts
of the ansible package:
  * 
https://github.com/ansible/community/wiki/User-testing-of-ansible-2.10-pre-releases

If you aren't sure where your bug falls, pick which you feel is
closest and the Community Team will always move it if needed

Thanks!

-Toshio Kuratomi

-- 
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...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/ansible-project/CAPrnkaS%3DNDNp5%3DHg52kR6dMa-pkpgsmpGO45DjaaP5b3xcMGOg%40mail.gmail.com.