Accept the new Openshift when it says 'no such target', which means it was already removed

Signed-off-by: Patrick Uiterwijk <patrick@puiterwijk.org>
This commit is contained in:
Patrick Uiterwijk 2018-12-04 21:14:25 +01:00
parent df5009d443
commit 00c27bb939

View file

@ -217,7 +217,7 @@
command: oc adm policy remove-cluster-role-from-group self-provisioner system:authenticated system:authenticated:oauth
changed_when: false
register: command_result
failed_when: "' removed:' not in command_result.stdout"
failed_when: "' removed:' not in command_result.stdout and 'unable to find target' not in command_result.stderr"
run_once: True
- name: Allow some users cluster admin
command: oadm policy add-cluster-role-to-user cluster-admin {{item}}