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! => {}
MSG:
The conditional check 'create_oml_users.rc == 0' failed. The error was:
error while evaluating conditional (create_oml_users.rc == 0):
'create_oml_users' is undefined
The error appears to have been in
'/etc/ansible/aix/roles/manage_ldap_users/tasks/main.yml': line 13, column 3
, but may
be elsewhere in the file depending on the exact syntax problem.
The offending line appears to be:
- shell: lsuser -R files lsam 2>/dev/null
^ here
...ignoring
Enter code here...
--
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/de7ab0a9-c460-46c8-a7b2-1a722d1f2bdf%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.