mirror of
https://github.com/ansible-collections/community.general.git
synced 2026-04-21 11:19:00 +00:00
[PR #11767/f4f2bfe8 backport][stable-12] openbsd_pkg, sorcery: ensure standard locale in run_command (group4-batch2) (#11793)
openbsd_pkg, sorcery: ensure standard locale in run_command (group4-batch2) (#11767)
* ensure standard locale in run_command (group4-batch2)
Adds ``LANGUAGE=C`` and ``LC_ALL=C`` to the ``environ_update`` passed to
``run_command()`` calls in modules that parse command output, to prevent
locale-dependent parsing failures on non-C-locale systems.
Modules updated: openbsd_pkg, sorcery.
* add changelog fragment for group4-batch2
* add changelog fragment for group4-batch2
---------
(cherry picked from commit f4f2bfe847)
Co-authored-by: Alexei Znamensky <103110+russoz@users.noreply.github.com>
Co-authored-by: Claude Sonnet 4.6 <noreply@anthropic.com>
This commit is contained in:
parent
d5a759b2e3
commit
d74e553f4b
3 changed files with 5 additions and 2 deletions
|
|
@ -166,7 +166,7 @@ def execute_command(cmd, module):
|
|||
# We set TERM to 'dumb' to keep pkg_add happy if the machine running
|
||||
# ansible is using a TERM that the managed machine does not know about,
|
||||
# e.g.: "No progress meter: failed termcap lookup on xterm-kitty".
|
||||
return module.run_command(cmd_args, environ_update={"TERM": "dumb"})
|
||||
return module.run_command(cmd_args, environ_update={"TERM": "dumb", "LANGUAGE": "C", "LC_ALL": "C"})
|
||||
|
||||
|
||||
def get_all_installed(module):
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue