mirror of
https://github.com/ansible-collections/community.general.git
synced 2026-05-06 05:12:45 +00:00
fix play_context connection_user attribute (#21640)
The connection user needs to be set from the original play_context and not the copy. This fixes that problem
This commit is contained in:
@@ -443,7 +443,7 @@ class PlayContext(Base):
|
||||
# additionally, we need to do this check after final connection has been
|
||||
# correctly set above ...
|
||||
if new_info.connection == 'local':
|
||||
new_info.connection_user = new_info.remote_user
|
||||
new_info.connection_user = self.remote_user
|
||||
new_info.remote_user = pwd.getpwuid(os.getuid()).pw_name
|
||||
|
||||
# set no_log to default if it was not previouslly set
|
||||
|
||||
Reference in New Issue
Block a user