Skip to content
Open
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
3 changes: 1 addition & 2 deletions docs/usage/advanced/podman.md
Original file line number Diff line number Diff line change
Expand Up @@ -88,8 +88,7 @@ Reference: [https://rootlesscontaine.rs/getting-started/common/cgroup2/#enabling
[Start Podman on the remote host](https://github.com/containers/podman/blob/main/docs/tutorials/remote_client.md), and then set `DOCKER_HOST` when running k3d:

```
export DOCKER_HOST=ssh://username@hostname
export DOCKER_SOCK=/run/user/1000/podman/podman.sock
export DOCKER_HOST=ssh://username@hostname/run/user/1000/podman/podman.sock
Copy link

Copilot AI Dec 4, 2025

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The removal of DOCKER_SOCK may cause issues with features that use the tools container. The DOCKER_SOCK environment variable is read by k3d's GetRuntimePath() function (in pkg/runtimes/docker/docker.go:96) and used to mount the socket into the tools container (in pkg/client/tools.go:436).

When DOCKER_SOCK is not set, it defaults to /var/run/docker.sock, which would be incorrect for rootless Podman where the socket is at /run/user/1000/podman/podman.sock. While including the socket path in the DOCKER_HOST SSH URL works for the Docker client library, k3d doesn't currently parse the socket path from SSH URLs in GetRuntimePath().

Consider either:

  1. Keeping DOCKER_SOCK as a separate variable (as shown in the macOS section examples at lines 138-140 and 148-149), or
  2. Updating k3d's code to extract the socket path from SSH-protocol DOCKER_HOST URLs

Note: Line 139 also has an inconsistency - it uses DOCKER_SOCKET instead of DOCKER_SOCK.

Suggested change
export DOCKER_HOST=ssh://username@hostname/run/user/1000/podman/podman.sock
export DOCKER_HOST=ssh://username@hostname/run/user/1000/podman/podman.sock
export DOCKER_SOCK=/run/user/1000/podman/podman.sock

Copilot uses AI. Check for mistakes.
k3d cluster create
```

Expand Down