2025-07-21 21:23:36 +02:00

127 lines
5.3 KiB
XML

<?xml version="1.0" encoding="UTF-8"?>
<project xmlns="http://maven.apache.org/POM/4.1.0"
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xsi:schemaLocation="http://maven.apache.org/POM/4.1.0 https://maven.apache.org/xsd/maven-4.1.0.xsd.0.xsd">
<modelVersion>4.0.0</modelVersion>
<groupId>se.su.dsv.asvanberg</groupId>
<artifactId>simple-docker-service</artifactId>
<version>1.0-SNAPSHOT</version>
<properties>
<maven.compiler.release>24</maven.compiler.release>
<project.build.sourceEncoding>UTF-8</project.build.sourceEncoding>
</properties>
<packaging>jlink</packaging>
<build>
<pluginManagement>
<plugins>
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-clean-plugin</artifactId>
<version>3.5.0</version>
</plugin>
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-compiler-plugin</artifactId>
<version>3.14.0</version>
</plugin>
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-resources-plugin</artifactId>
<version>3.3.1</version>
</plugin>
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-surefire-plugin</artifactId>
<version>3.5.2</version>
</plugin>
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-jlink-plugin</artifactId>
<version>3.2.0</version>
</plugin>
<plugin>
<groupId>org.codehaus.mojo</groupId>
<artifactId>exec-maven-plugin</artifactId>
<version>3.5.1</version>
</plugin>
</plugins>
</pluginManagement>
<plugins>
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-compiler-plugin</artifactId>
<configuration>
<release>24</release>
</configuration>
</plugin>
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-jlink-plugin</artifactId>
<extensions>true</extensions>
</plugin>
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-clean-plugin</artifactId>
<executions>
<execution>
<!-- jpackage output directory must not exist before jpackage is run -->
<id>remove-previous-jpackage</id>
<phase>after:package[100]</phase>
<goals>
<goal>clean</goal>
</goals>
<configuration>
<excludeDefaultDirectories>true</excludeDefaultDirectories>
<!-- the generated binary executable is read-only which means force is required -->
<force>true</force>
<filesets>
<fileset>
<directory>${project.build.directory}/${project.artifactId}</directory>
<includes>
<include>**</include>
</includes>
</fileset>
</filesets>
</configuration>
</execution>
</executions>
</plugin>
<plugin>
<groupId>org.codehaus.mojo</groupId>
<artifactId>exec-maven-plugin</artifactId>
<executions>
<execution>
<id>jpackage</id>
<phase>after:package[200]</phase>
<goals>
<goal>exec</goal>
</goals>
</execution>
</executions>
<configuration>
<addOutputToClasspath>false</addOutputToClasspath>
<executable>jpackage</executable>
<workingDirectory>${project.build.directory}</workingDirectory>
<arguments>
<argument>--type</argument>
<argument>app-image</argument>
<argument>--name</argument>
<argument>${project.artifactId}</argument>
<argument>--runtime-image</argument>
<argument>${project.build.directory}/maven-jlink/default</argument>
<argument>--module</argument>
<argument>se.su.dsv.asvanberg.sds/se.su.dsv.asvanberg.sds.Main</argument>
</arguments>
</configuration>
</plugin>
</plugins>
</build>
</project>