From f317fd924ae512755cbe1e7d97623eddbc4f7ce3 Mon Sep 17 00:00:00 2001 From: "patchback[bot]" <45432694+patchback[bot]@users.noreply.github.com> Date: Sat, 15 Jul 2023 16:27:26 +0200 Subject: [PATCH] [PR #6935/24feb1dd backport][stable-7] machinectl become plugin: mark as require_tty (#6942) machinectl become plugin: mark as require_tty (#6935) Mark machinectl become plugin as require_tty. (cherry picked from commit 24feb1dd10f86c87a4fac623dd9095f7ead3c8b7) Co-authored-by: Felix Fontein --- changelogs/fragments/6935-machinectl-become.yml | 2 ++ plugins/become/machinectl.py | 1 + 2 files changed, 3 insertions(+) create mode 100644 changelogs/fragments/6935-machinectl-become.yml diff --git a/changelogs/fragments/6935-machinectl-become.yml b/changelogs/fragments/6935-machinectl-become.yml new file mode 100644 index 0000000000..fe1fcc6273 --- /dev/null +++ b/changelogs/fragments/6935-machinectl-become.yml @@ -0,0 +1,2 @@ +bugfixes: + - "machinectl become plugin - mark plugin as ``require_tty`` to automatically disable pipelining, with which this plugin is not compatible (https://github.com/ansible-collections/community.general/issues/6932, https://github.com/ansible-collections/community.general/pull/6935)." diff --git a/plugins/become/machinectl.py b/plugins/become/machinectl.py index 53d562e598..9b9ac7ec51 100644 --- a/plugins/become/machinectl.py +++ b/plugins/become/machinectl.py @@ -102,6 +102,7 @@ class BecomeModule(BecomeBase): prompt = 'Password: ' fail = ('==== AUTHENTICATION FAILED ====',) success = ('==== AUTHENTICATION COMPLETE ====',) + require_tty = True # see https://github.com/ansible-collections/community.general/issues/6932 @staticmethod def remove_ansi_codes(line):