On 19.09.2018 12:16, [email protected] wrote:
how to i check the return code of a shell command correctly? see error
below. looks like a chicken/egg situation to me...create_oml_users should
be registerd if rc is 0...any ideas?


- shell: lsuser -R files lsam 2>/dev/null
  register: create_oml_users
  when: create_oml_users.rc == 0
  ignore_errors: true

fatal: [AIXWUKIT]: FAILED! => {}

You must do that in the next task, not in the task itself.

--
Kai Stian Olstad

--
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/4085d6c3375881d7363ef112097d4e01%40olstad.com.
For more options, visit https://groups.google.com/d/optout.

Reply via email to