Hi, I am new to ocurrent and learning it via its examples in the doc.
My question is how ocurrent finds the path for docker
.
I am using wsl2. I installed a legacy Docker for Windows, so I have seen this before
The command 'docker' could not be found in this WSL 2 distro.
We recommend to activate the WSL integration in Docker Desktop settings.
However, today I installed podman as a docker alternative (for fun).
Then I removed the soft links in /bin/docker
and /usr/bin/docker
and make a new softlink to podman
instead.
⋊> which -a docker
/bin/docker
/usr/bin/docker
/bin/docker
/mnt/c/Program Files/Docker/Docker/resources/bin/docker
⋊> ls -al /bin/docker | grep docker
lrwxrwxrwx 1 root root 6 Jan 26 23:38 /bin/docker -> podman
⋊> ls -al /usr/bin/docker | grep docker
lrwxrwxrwx 1 root root 6 Jan 26 23:38 /usr/bin/docker -> podman
The result is the same for both my shell and /bin/sh/
. I can run the fake docker
on my own.
The strange thing is I can still read the error message for the legacy docker in the ocurrent log.
2022-01-27 04:05.07: Exec: "docker" "build" "-f" "/tmp/git-checkout29b7fa22/Dockerfile"
"--iidfile" "/tmp/git-checkout29b7fa22/docker-iid"
"--" "/tmp/git-checkout29b7fa22"
The command 'docker' could not be found in this WSL 2 distro.
We recommend to activate the WSL integration in Docker Desktop settings.
I wonder how the ocurrent find the paths for a command e.g. docker
and then I can think how to fix my problem.