Because I said it's a role and you put them as tasks ;) On Wednesday, February 15, 2017 at 8:51:37 AM UTC+2, Adrian Paraschiv wrote: > > I have ansible 2.2.1.0 and I have this role: > > - block: > - shell: echo 1 > - shell: fail > - shell: echo 2 > rescue: > - shell: echo 3 > always: > - shell: echo 4 > > - name: running something after the block > shell: echo 5 > > > If I run this role, the first part of the block fails because of the > "fail" command (which does not exist :) "stderr: /bin/sh: 1: fail: not > found") so the rescue kicks + always. But the last task, the one "running > something after the block" never runs. The play finises! > > Why is that ? The expected result I would see it as: if the first part of > the block fails rescue kicks in + always (if any) and then continues the > play run with the rest of the tasks. > > In the documentation there is nothing about this. > > Is there a workaround this ? >
-- 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/1d6082c5-8576-4ed0-b376-a958f11f45df%40googlegroups.com. For more options, visit https://groups.google.com/d/optout.
