# Io.fabric8:docker-maven-plugin 调用 Docker 显示 DOCKER\_HOST 错误

**URL:** <https://www.isharkfly.com/t/io-fabric8-docker-maven-plugin-docker-docker-host/14597>\
**Category:** DevOps\
**Tags:** maven, docker\
**Created:** [September 3, 2023, 11:52pm UTC](https://www.isharkfly.com/t/io-fabric8-docker-maven-plugin-docker-docker-host/14597 "2023-09-03T23:52:14Z")\
**Posts on this page:** 1\
**Page:** 1

<div class="post-metadata">

**Author:** ![honeymoose](https://www.isharkfly.com/user_avatar/www.isharkfly.com/honeymoose/32/20796_2.png) [@honeymoose](https://www.isharkfly.com/u/honeymoose)\
**Post date:** [September 3, 2023, 11:52pm UTC](https://www.isharkfly.com/t/io-fabric8-docker-maven-plugin-docker-docker-host/14597/1 "2023-09-03T23:52:14Z")

</div>

执行编译的时候提示错误信息：

```auto
[INFO] 
[INFO] --- docker-maven-plugin:0.44.0:build (default) @ service ---
[INFO] ------------------------------------------------------------------------
[INFO] BUILD FAILURE
[INFO] ------------------------------------------------------------------------
[INFO] Total time: 26.841 s
[INFO] Finished at: 2025-03-28T13:11:45Z
[INFO] ------------------------------------------------------------------------
[ERROR] Failed to execute goal io.fabric8:docker-maven-plugin:0.44.0:build (default) on project service: Execution default of goal io.fabric8:docker-maven-plugin:0.44.0: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]
[ERROR] 
[ERROR] To see the full stack trace of the errors, re-run Maven with the -e switch.
[ERROR] Re-run Maven using the -X switch to enable full debug logging.
[ERROR] 
[ERROR] For more information about the errors and possible solutions, please read the following articles:
[ERROR] [Help 1] http://cwiki.apache.org/confluence/display/MAVEN/PluginExecutionException

```

 ![2025-03-28_14-42-59](https://cdn.isharkfly.com/com-isharkfly-www/discourse-uploads/original/3X/d/1/d1890601cdcdb6937c34d980f19e61a01c263386.jpeg)

## 问题和解决

可能有下面的错误：[Jenkins 构建的时候提示 DOCKER\_HOST 错误](https://www.isharkfly.com/t/jenkins-docker-host/14191)

更主要的，是 Docker 引擎进程没有启动。

需要启动 Docker 进程。
