mirror of
https://github.com/ansible-collections/community.docker.git
synced 2025-12-16 03:52:05 +00:00
(cherry picked from commit 33c8a49191)
This commit is contained in:
parent
091f04bd9d
commit
b058cd40da
4
changelogs/fragments/1161-fix.yml
Normal file
4
changelogs/fragments/1161-fix.yml
Normal file
@ -0,0 +1,4 @@
|
||||
bugfixes:
|
||||
- "docker connection plugin - fix crash instead of warning if Docker version does not support ``remote_user`` (https://github.com/ansible-collections/community.docker/pull/1161)."
|
||||
- "docker_compose_v2_exec - fix crash instead of reporting error if ``detach=true`` and ``stdin`` is provided (https://github.com/ansible-collections/community.docker/pull/1161)."
|
||||
- "docker_compose_v2_run - fix crash instead of reporting error if ``detach=true`` and ``stdin`` is provided (https://github.com/ansible-collections/community.docker/pull/1161)."
|
||||
@ -320,7 +320,7 @@ class Connection(ConnectionBase):
|
||||
actual_user = self._get_docker_remote_user()
|
||||
if actual_user != self.get_option('remote_user'):
|
||||
display.warning(u'docker {0} does not support remote_user, using container default: {1}'
|
||||
.format(self.docker_version, self.actual_user or u'?'))
|
||||
.format(self.docker_version, actual_user or u'?'))
|
||||
return actual_user
|
||||
elif self._display.verbosity > 2:
|
||||
# Since we are not setting the actual_user, look it up so we have it for logging later
|
||||
|
||||
@ -203,7 +203,7 @@ class ExecManager(BaseComposeManager):
|
||||
self.argv = shlex.split(parameters['command'])
|
||||
|
||||
if self.detach and self.stdin is not None:
|
||||
self.mail('If detach=true, stdin cannot be provided.')
|
||||
self.fail('If detach=true, stdin cannot be provided.')
|
||||
|
||||
if self.stdin is not None and parameters['stdin_add_newline']:
|
||||
self.stdin += '\n'
|
||||
|
||||
@ -289,7 +289,7 @@ class ExecManager(BaseComposeManager):
|
||||
self.argv = shlex.split(parameters['command'])
|
||||
|
||||
if self.detach and self.stdin is not None:
|
||||
self.mail('If detach=true, stdin cannot be provided.')
|
||||
self.fail('If detach=true, stdin cannot be provided.')
|
||||
|
||||
if self.stdin is not None and parameters['stdin_add_newline']:
|
||||
self.stdin += '\n'
|
||||
|
||||
Loading…
Reference in New Issue
Block a user