Ok, good deal, thanks for checking on the latest - can you please file a
github ticket on this one?

Thanks!


On Mon, Aug 18, 2014 at 3:20 PM, Andrew Martin <[email protected]>
wrote:

> I tried this test again after upgrading to 1.7 and the behavior is the
> same: the task is listed as changed and the handler as NOTIFIED, but it is
> skipped
>
>
> On Tuesday, 12 August 2014 13:33:12 UTC-5, Michael DeHaan wrote:
>
>> So the first thing I notice is this ticket was filed on 1.6.2.
>>
>> The current released version of Ansible is 1.7.0, have you checked on the
>> latest?
>>
>> Not saying this is not a thing, but would save us time and we'd
>> appreciate the updated report.
>>
>> Thanks!
>>
>>
>>
>>
>> On Tue, Aug 12, 2014 at 1:09 PM, Andrew Martin <[email protected]>
>> wrote:
>>
>>> Hello,
>>>
>>> See https://github.com/ansible/ansible/issues/8559 for additional
>>> details, but in brief I have 3 roles:
>>>
>>> roles/apache2/meta/main.yml:
>>>
>>>> ---
>>>> allow_duplicates: yes
>>>
>>>
>>> roles/apache2-php/meta/main.yml:
>>>
>>>> ---
>>>> allow_duplicates: yes
>>>> dependencies:
>>>>   - { role: apache2 }
>>>
>>>
>>> roles/apache2-ssl/meta/main.yml:
>>>
>>>> ---
>>>
>>> allow_duplicates: yes
>>>
>>> dependencies:
>>>>   - { role: apache2-php, when: include_php == True }
>>>>   - { role: apache2, when: include_php == False }
>>>
>>>
>>> I would like to be able to use the apache2-ssl role in a playbook and
>>> have it recursively call the apache2-php and apache2 dependent roles. This
>>> works for the most part, except with handlers in the base apache2 role.
>>> Even with allow_duplicates: yes everywhere, when I call the apache2-ssl
>>> role with include_php == False, the "reload apache" handler still gets
>>> skipped:
>>>
>>> excerpt from roles/apache2/tasks/main.yml:
>>>
>>>>  - name: copy apache configuration (12.04)
>>>>    template: src=000-default.j2 dest=/etc/apache2/sites-
>>>> enabled/000-default
>>>>    when: ansible_distribution_version == "12.04"
>>>>    notify: reload apache2
>>>
>>>
>>> excerpt from roles/apache2/handlers/main.yml:
>>>
>>>>   - name: reload apache2
>>>>     service: name=apache2 state=reloaded enabled=true
>>>
>>>
>>> The handler is NOTIFIED, but skipped:
>>>
>>>> NOTIFIED: [apache2 | reload apache2] ******************************
>>>> ************
>>>> skipping: [apachetest]
>>>
>>> I think this occurs because the first dependent role, apache2-php, is
>>> skipped because include_php is False. It then recusively marks all tasks
>>> and handlers in apache2-php and apache2 as skipped, and then when it goes
>>> to apache2 a second time (when it hits the second dependent role), it is
>>> already marked as skipped and so the handler doesn't execute. Any ideas on
>>> what is going on here, and how to fix it?
>>>
>>> Thanks!
>>>
>>> --
>>> 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 [email protected].
>>> To post to this group, send email to [email protected].
>>>
>>> To view this discussion on the web visit https://groups.google.com/d/
>>> msgid/ansible-project/0f5254b0-4f0c-4f2b-89d4-
>>> 3a920aad986b%40googlegroups.com
>>> <https://groups.google.com/d/msgid/ansible-project/0f5254b0-4f0c-4f2b-89d4-3a920aad986b%40googlegroups.com?utm_medium=email&utm_source=footer>
>>> .
>>> For more options, visit https://groups.google.com/d/optout.
>>>
>>
>>  --
> 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 [email protected].
> To post to this group, send email to [email protected].
> To view this discussion on the web visit
> https://groups.google.com/d/msgid/ansible-project/c51015b5-e62a-4841-bc58-e3cf70eaf793%40googlegroups.com
> <https://groups.google.com/d/msgid/ansible-project/c51015b5-e62a-4841-bc58-e3cf70eaf793%40googlegroups.com?utm_medium=email&utm_source=footer>
> .
>
> For more options, visit https://groups.google.com/d/optout.
>

-- 
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 [email protected].
To post to this group, send email to [email protected].
To view this discussion on the web visit 
https://groups.google.com/d/msgid/ansible-project/CA%2BnsWgzwiWyOUKU8VjYnS78AB6PFLkA_4fnn5HRtFDU-H%2BMUZA%40mail.gmail.com.
For more options, visit https://groups.google.com/d/optout.

Reply via email to