在pom.xml中添加
<plugin>
<groupId>com.google.cloud.tools</groupId>
<artifactId>jib-maven-plugin</artifactId>
<version>3.4.0</version>
<configuration>
<from>
<image>dev.flyrise.cn:8082/library/openjdk:21-alpine</image>
</from>
<!--构建后的镜像名称以及私服地址、鉴权信息-->
<to>
<image>dev.flyrise.cn:8082/pi-dev/pai-auth:v2024.0.0.0-RC1</image>
<auth>
<username>***</username>
<password>***</password>
</auth>
<!--允许非https pai-->
</to>
<container>
<!--要暴露的端口-->
<ports>
<port>8080</port>
</ports>
<filesModificationTime>EPOCH_PLUS_SECOND</filesModificationTime>
</container>
<!--允许非https-->
<allowInsecureRegistries>true</allowInsecureRegistries>
</configuration>
</plugin>
文档更新时间: 2024-03-27 10:58 作者:朱灿奕