# ee835ff  does not fix #11746

**URL:** <https://forum.ansible.com/t/ee835ff-does-not-fix-11746/18867>\
**Category:** Ansible Developer\
**Created:** [July 27, 2015, 7:55pm UTC](https://forum.ansible.com/t/ee835ff-does-not-fix-11746/18867 "2015-07-27T19:55:32Z")\
**Posts on this page:** 5\
**Page:** 1

<div class="post-metadata">

**Author:** ![Bob\_Tanner](https://avatars.discourse-cdn.com/v4/letter/b/49beb7/32.png) [@Bob\_Tanner](https://forum.ansible.com/u/Bob_Tanner)\
**Post date:** [July 27, 2015, 7:55pm UTC](https://forum.ansible.com/t/ee835ff-does-not-fix-11746/18867/1 "2015-07-27T19:55:32Z")

</div>

[ee835ff](https://github.com/ansible/ansible/commit/ee835ff7adf05e53360c1210a592afa5cdebb268) does not fixed [#11746](https://github.com/ansible/ansible/issues/11746) (posting here because the issue was closed)

Here is the play, pretty must the same as the play in #11746

- name: deploy ssl keys and certificates  
copy: \>  
src={{ item }}  
dest=/etc/ssl/private/  
owner=root  
group=ssl-cert  
mode=0640  
with\_fileglob:
- private/\*.key
- private/\*.crt
- z\*  
sudo: yes  
tags: nagios

Example run

$ source hacking/env-setup  
$ cd …/playbooks/  
$ ansible-playbook -i vagrant\_inventory --private-key private\_key -u vagrant vagrant.yml -vv  
PLAY \*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*  
TASK [setup] \*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*  
ok: [default]  
  
TASK [nagios-servers : deploy ssl keys and certificates] \*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*

changed: [default] =\> {“changed”: true, “msg”: “All items completed”, “results”: [{“changed”: true, “checksum”: “e438cb27db8f5a95d30895eb026a4bc054a4880a”, “dest”: “/etc/ssl/private/zimbra-test.yml”, “gid”: 115, “group”: “ssl-cert”, “item”: “/Volumes/Warrior1TB/Users/tanner/projects/ansible.git/playbooks/zimbra-test.yml”, “md5sum”: “77192f7a54aef85b11ce8e6a56e21be7”, “mode”: “0640”, “owner”: “root”, “size”: 97, “src”: “/home/vagrant/.ansible/tmp/ansible-tmp-1438026036.31-70839668423767/source”, “state”: “file”, “uid”: 0}]}

Directory layout of the nagios-servers role

nagios-servers/defaults/main.yml  
nagios-servers/files/private/nagios1.crt  
nagios-servers/files/private/nagios1.key  
nagios-servers/files/private/nagios2.crt

nagios-servers/files/private/nagios2.key  
nagios-servers/files/zzzzz

nagios-servers/handlers/main.yml  
nagios-servers/meta/main.yml  
nagios-servers/README.md  
nagios-servers/tasks/debian.yml  
nagios-servers/tasks/main.yml  
nagios-servers/templates/nagios3.j2  
nagios-servers/vars/main.yml

You can see there are 2 keys and 2 certificates in the files/private/ directory but the with\_fileglob: does not pick them up. But the with\_fileglob: does pick up the zimbra-test.yml in the ansible.git/playbooks/ directory.

$ ansible --version  
ansible 2.0.0 (devel 010e58ebfa) last updated 2015/07/27 14:37:44 (GMT -500)  
lib/ansible/modules/core: (detached HEAD bc60c893f5) last updated 2015/07/27 14:37:45 (GMT -500)  
lib/ansible/modules/extras: (detached HEAD 14fffa5b53) last updated 2015/07/24 12:24:44 (GMT -500)  
v1/ansible/modules/core: (detached HEAD f8d8af17cd) last updated 2015/06/03 00:37:54 (GMT -500)  
v1/ansible/modules/extras: (detached HEAD 495ad450e5) last updated 2015/06/03 00:37:58 (GMT -500)  
config file =  
configured module search path = None

---

<div class="post-metadata">

**Author:** ![James\_Cammarata](https://avatars.discourse-cdn.com/v4/letter/j/7c8e57/32.png) [@James\_Cammarata](https://forum.ansible.com/u/James_Cammarata)\
**Post date:** [July 27, 2015, 8:04pm UTC](https://forum.ansible.com/t/ee835ff-does-not-fix-11746/18867/2 "2015-07-27T20:04:16Z")

</div>

Sorry Bob, I didn’t test this well enough apparently, I’ll look into it.

---

<div class="post-metadata">

**Author:** ![James\_Cammarata](https://avatars.discourse-cdn.com/v4/letter/j/7c8e57/32.png) [@James\_Cammarata](https://forum.ansible.com/u/James_Cammarata)\
**Post date:** [July 27, 2015, 8:37pm UTC](https://forum.ansible.com/t/ee835ff-does-not-fix-11746/18867/3 "2015-07-27T20:37:14Z")

</div>

Hi Bob, I just pushed d6cafff2f95f3cf2f8c6532da67170b535da2816 to address this, and tested against your example successfully. Let us know if you’re still seeing problems.

Thanks!

---

<div class="post-metadata">

**Author:** ![Bob\_Tanner](https://avatars.discourse-cdn.com/v4/letter/b/49beb7/32.png) [@Bob\_Tanner](https://forum.ansible.com/u/Bob_Tanner)\
**Post date:** [July 27, 2015, 9:04pm UTC](https://forum.ansible.com/t/ee835ff-does-not-fix-11746/18867/4 "2015-07-27T21:04:43Z")

</div>

That looks to have fixed the problem. Thanks!

---

<div class="post-metadata">

**Author:** ![Bob\_Tanner](https://avatars.discourse-cdn.com/v4/letter/b/49beb7/32.png) [@Bob\_Tanner](https://forum.ansible.com/u/Bob_Tanner)\
**Post date:** [July 27, 2015, 9:05pm UTC](https://forum.ansible.com/t/ee835ff-does-not-fix-11746/18867/5 "2015-07-27T21:05:26Z")

</div>

That looks to have fixed the problem. Thanks!
