docker-install icon indicating copy to clipboard operation
docker-install copied to clipboard

request: XDG_RUNTIME_DIR for the default docker cli rootless binary

Open idesk2596 opened this issue 4 years ago • 1 comments

Hi,

Can the docker rootless cli defaults to connect to $XDG_RUNTIME_DIR/docker.sock instead of /var/run/docker.sock if no DOCKER_HOST or --context, and relatives defined?

Client:
 Context:    default
 Debug Mode: false
 Plugins:
  buildx: Build with BuildKit (Docker Inc., v0.6.3)

Server:
ERROR: Cannot connect to Docker daemon at unix:///var/run/docker.sock. Is the docker daemon running?
errors pretty printing info

it make sense as this is for rootless..

similar to podman approach - "path defaults to either /run/podman/podman.sock, or /run/user/<uid>/podman/podman.sock if running rootless."

Thanks.

idesk2596 avatar Nov 03 '21 10:11 idesk2596

Rootless Docker v22 will use rootless context by default:

  • https://github.com/moby/moby/pull/43061

AkihiroSuda avatar Feb 08 '22 07:02 AkihiroSuda