Skip to content

Instantly share code, notes, and snippets.

@stefanotroia
Created November 5, 2019 17:17
Show Gist options
  • Save stefanotroia/ea2030c562640a57c06c778f137c33e6 to your computer and use it in GitHub Desktop.
Save stefanotroia/ea2030c562640a57c06c778f137c33e6 to your computer and use it in GitHub Desktop.
Pom xml with jib plugin
<?xml version="1.0" encoding="UTF-8"?>
<plugin>
<groupId>com.google.cloud.tools</groupId>
<artifactId>jib-maven-plugin</artifactId>
<version>1.1.2</version>
<configuration>
<from>
<image>openjdk:8-jre-alpine</image>
</from>
<to>
<image>${registry.url}/${project.name}:${project.name}</image>
</to>
<container>
<useCurrentTimestamp>true</useCurrentTimestamp>
<mainClass>it.yourComany.MainClass</mainClass>
<ports>
<port>8080/tcp</port>
</ports>
</container>
</configuration>
</plugin>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment