orlangure/gnomock

Bug: DOCKER_HOST "unix:///run/user/1000/docker.sock" does not work

MaksimSkorobogatov opened this issue · 1 comments

Describe the bug
I have a rootless docker installation on localhost. I set env variable DOCKER_HOST to "unix:///run/user/1000/docker.sock". Docker work and gnomock does not. If I'm not mistaken, this feature worked when the docker version was old in go.mod.

To Reproduce
Set environment variable DOCKER_HOST="unix:///run/user/1000/docker.sock" and run anything using gnomock.

Expected behavior
The file /run/user/1000/docker.sock will be used for docker sock instead of /var/run/docker.sock.

System:

  • OS: GNU/Linux amd64.
  • Docker version: 20.10.3.

Additional context
I have seen the problem in code: with remote DOCKER_HOST support, the hostname is processed and the path is lost. I can open PR to fix.

Hi @MaksimSkorobogatov, thanks for the report.

Please try running your tests using #141, or wait until I merge and release this fix.