Windows 打包 Docker 提示环境错误: no DOCKER_HOST environment variable

发布时间 2023-09-16 05:08:12作者: huyuchengus

这个问题应该还是比较常见的。

[ERROR] Failed to execute goal io.fabric8:docker-maven-plugin:0.40.2:build (default) on project mq-service: Execution default of goal io.fabric8:docker-maven-plugin:0.40.2:build failed: No <dockerHost> given, no DOCKER_HOST environment variable, no read/writable '/var/run/docker.sock' or '//./pipe/docker_engine' and no external provider like Docker machine configured -> [Help 1]

 

 

问题和解决

这个问题的主要原因是在我们本地运行的计算机中,Docker Desktop 没有启动。

这个需要启动下才能打包。

 

 

直接把这个挂起来运行就好了。

 

https://www.isharkfly.com/t/windows-docker-no-docker-host-environment-variable/14966