docker / cli

The Docker CLI
Apache License 2.0
4.97k stars 1.94k forks source link

Remove hardcoded `docker` CLI command name for SSH hosts #5626

Open mattmacleod opened 1 week ago

mattmacleod commented 1 week ago

Description

Currently, when connecting to a remote SSH host, the docker binary name is hard-coded.. This means that if the remote host doesn't have a binary named docker in the path, remote SSH support doesn't work.

There are two specific use-cases this makes difficult:

If this hard-coded default could be overridden, these use-cases could be supported.

Proposal

Introduce the DOCKER_SSH_REMOTE_BINARY environment variable, which will be used in place of the bare docker binary if set. I'll raise a PR for this change then link to it.

Associated PR: https://github.com/docker/cli/pull/5627

Related

Would resolve https://github.com/docker/cli/issues/3045