|
|
@ -11,6 +11,11 @@
|
|
|
|
become_user: mitogen__pw_required
|
|
|
|
become_user: mitogen__pw_required
|
|
|
|
register: out
|
|
|
|
register: out
|
|
|
|
ignore_errors: true
|
|
|
|
ignore_errors: true
|
|
|
|
|
|
|
|
when:
|
|
|
|
|
|
|
|
# https://github.com/ansible/ansible/pull/70785
|
|
|
|
|
|
|
|
- ansible_facts.distribution not in ["MacOSX"]
|
|
|
|
|
|
|
|
or ansible_version.full is version("2.11", ">=", strict=True)
|
|
|
|
|
|
|
|
or is_mitogen
|
|
|
|
|
|
|
|
|
|
|
|
- assert:
|
|
|
|
- assert:
|
|
|
|
that: |
|
|
|
|
that: |
|
|
|
@ -20,6 +25,11 @@
|
|
|
|
('password is required' in out.module_stderr)
|
|
|
|
('password is required' in out.module_stderr)
|
|
|
|
)
|
|
|
|
)
|
|
|
|
fail_msg: out={{out}}
|
|
|
|
fail_msg: out={{out}}
|
|
|
|
|
|
|
|
when:
|
|
|
|
|
|
|
|
# https://github.com/ansible/ansible/pull/70785
|
|
|
|
|
|
|
|
- ansible_facts.distribution not in ["MacOSX"]
|
|
|
|
|
|
|
|
or ansible_version.full is version("2.11", ">=", strict=True)
|
|
|
|
|
|
|
|
or is_mitogen
|
|
|
|
|
|
|
|
|
|
|
|
- name: Ensure password sudo incorrect.
|
|
|
|
- name: Ensure password sudo incorrect.
|
|
|
|
shell: whoami
|
|
|
|
shell: whoami
|
|
|
@ -29,6 +39,11 @@
|
|
|
|
vars:
|
|
|
|
vars:
|
|
|
|
ansible_become_pass: nopes
|
|
|
|
ansible_become_pass: nopes
|
|
|
|
ignore_errors: true
|
|
|
|
ignore_errors: true
|
|
|
|
|
|
|
|
when:
|
|
|
|
|
|
|
|
# https://github.com/ansible/ansible/pull/70785
|
|
|
|
|
|
|
|
- ansible_facts.distribution not in ["MacOSX"]
|
|
|
|
|
|
|
|
or ansible_version.full is version("2.11", ">=", strict=True)
|
|
|
|
|
|
|
|
or is_mitogen
|
|
|
|
|
|
|
|
|
|
|
|
- assert:
|
|
|
|
- assert:
|
|
|
|
that: |
|
|
|
|
that: |
|
|
|
@ -37,6 +52,11 @@
|
|
|
|
('sudo password is incorrect' in out.msg)
|
|
|
|
('sudo password is incorrect' in out.msg)
|
|
|
|
)
|
|
|
|
)
|
|
|
|
fail_msg: out={{out}}
|
|
|
|
fail_msg: out={{out}}
|
|
|
|
|
|
|
|
when:
|
|
|
|
|
|
|
|
# https://github.com/ansible/ansible/pull/70785
|
|
|
|
|
|
|
|
- ansible_facts.distribution not in ["MacOSX"]
|
|
|
|
|
|
|
|
or ansible_version.full is version("2.11", ">=", strict=True)
|
|
|
|
|
|
|
|
or is_mitogen
|
|
|
|
|
|
|
|
|
|
|
|
# TODO: https://github.com/dw/mitogen/issues/692
|
|
|
|
# TODO: https://github.com/dw/mitogen/issues/692
|
|
|
|
# - name: Ensure password sudo succeeds.
|
|
|
|
# - name: Ensure password sudo succeeds.
|
|
|
|