diff options
author | Shane Smith <shane.smith@shopify.com> | 2022-07-04 12:17:11 -0400 |
---|---|---|
committer | Shane Smith <shane.smith@shopify.com> | 2022-07-04 12:23:46 -0400 |
commit | 8601ab6b06ceb19bf07ebea47177ae1893faece8 (patch) | |
tree | fdf3343d21e017f46feaa1fa93ae64a34a896d38 /pkg/machine | |
parent | a406b950e4f8cf64bdd2c1e03a8480d4b5f97226 (diff) | |
download | podman-8601ab6b06ceb19bf07ebea47177ae1893faece8.tar.gz podman-8601ab6b06ceb19bf07ebea47177ae1893faece8.tar.bz2 podman-8601ab6b06ceb19bf07ebea47177ae1893faece8.zip |
Silence setlocale warnings from `podman machine ssh`
Connecting with `podman machine ssh` can results in the following
warning:
```
/usr/bin/sh: warning: setlocale: LC_ALL: cannot change locale (en_CA.UTF-8)
/usr/bin/sh: warning: setlocale: LC_ALL: cannot change locale (en_CA.UTF-8)
/usr/bin/sh: warning: setlocale: LC_ALL: cannot change locale (en_CA.UTF-8)
/usr/bin/sh: warning: setlocale: LC_ALL: cannot change locale (en_CA.UTF-8)
```
Best would probably be to remove `LC_ALL` (and other locale and lang
env vars) from `/etc/ssh/sshd_config.d/50-redhat.conf` in the CoreOS
image, but I'm not terribly sure how, so this is a quick alternative.
[NO NEW TESTS NEEDED]
Signed-off-by: Shane Smith <shane.smith@shopify.com>
Diffstat (limited to 'pkg/machine')
-rw-r--r-- | pkg/machine/qemu/machine.go | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/pkg/machine/qemu/machine.go b/pkg/machine/qemu/machine.go index 2fe0230cf..7e9c786a9 100644 --- a/pkg/machine/qemu/machine.go +++ b/pkg/machine/qemu/machine.go @@ -1013,7 +1013,7 @@ func (v *MachineVM) SSH(_ string, opts machine.SSHOptions) error { port := strconv.Itoa(v.Port) args := []string{"-i", v.IdentityPath, "-p", port, sshDestination, "-o", "UserKnownHostsFile=/dev/null", - "-o", "StrictHostKeyChecking=no", "-o", "LogLevel=ERROR"} + "-o", "StrictHostKeyChecking=no", "-o", "LogLevel=ERROR", "-o", "SetEnv=LC_ALL="} if len(opts.Args) > 0 { args = append(args, opts.Args...) } else { |