diff --git a/examples/playbook/ansible.cfg b/examples/playbook/ansible.cfg index 367f2b02..b64b1b0e 100644 --- a/examples/playbook/ansible.cfg +++ b/examples/playbook/ansible.cfg @@ -1,5 +1,4 @@ [defaults] -sudo_flags = -HE inventory = hosts strategy_plugins = ../../ansible_mitogen/plugins/strategy library = modules diff --git a/mitogen/sudo.py b/mitogen/sudo.py index 5814e0a6..701a23ca 100644 --- a/mitogen/sudo.py +++ b/mitogen/sudo.py @@ -52,14 +52,14 @@ SUDO_OPTIONS = [ #(False, 'bool', '--remove-timestamp', '-K') #(False, 'bool', '--reset-timestamp', '-k') #(False, 'bool', '--list', '-l') - #(False, 'bool', '--non-interactive', '-n') #(False, 'bool', '--preserve-groups', '-P') #(False, 'str', '--prompt', '-p') #(False, 'str', '--role', '-r') - # For now the password is always typed interactively on a TTY, so accept - # this option but do not pass it through. + # These options are supplied by default by Ansible, but are ignored, as + # sudo always runs under a TTY with Mitogen. (True, 'bool', '--stdin', '-S'), + (True, 'bool', '--non-interactive', '-n'), #(False, 'str', '--shell', '-s') #(False, 'str', '--type', '-t')