idea 打包鏡像時 出現: An HTTPS URI for DOCKER_HOST must be provided to use Docker client certificates
其中<dockerHost>http://10.162.65.225:2375</dockerHost> 修改為 https也會把報錯
<configuration>
<!--指定生成的鏡像名-->
<imageName>docker/${project.artifactId}</imageName>
<!--指定標簽-->
<imageTags>
<imageTag>latest</imageTag>
</imageTags>
<!-- 指定 Dockerfile 路徑-->
<dockerDirectory>${project.basedir}/src/main/docker</dockerDirectory>
<!--指定遠程 docker api地址-->
<dockerHost>http://10.162.65.225:2375</dockerHost>
<!-- 這里是復制 jar 包到 docker 容器指定目錄配置 -->
<resources>
<resource>
<targetPath>/</targetPath>
<!--jar 包所在的路徑 此處配置的 即對應 target 目錄-->
<directory>${project.build.directory}</directory>
<!-- 需要包含的 jar包 ,這里對應的是 Dockerfile中添加的檔案名 -->
<include>${project.build.finalName}.jar</include>
</resource>
</resources>
</configuration>
轉載請註明出處,本文鏈接:https://www.uj5u.com/qita/30790.html
標籤:Docker
上一篇:云計算技術深海在那里?
