Spring Boot: Creating deployable fat jars

In our last two blog entries we pushed a sample Spring Boot application to Pivotal Cloud Foundry. For this purpose we had to create a so called “fat” .jar file first. This .jar file contains all the Spring Boot dependencies, typically including a Tomcat server. In order to build such a .jar file a <build> <plugin>.. tag has to be placed in the pom.xml of the application like this:

Spring Boot does all the necessary versioning!

All the developer has to do now is to head to start the command line, head into the project folder and invoke the “mvn package” command. This is the result:

 

Kommentar absenden

Deine E-Mail-Adresse wird nicht veröffentlicht. Erforderliche Felder sind mit * markiert.