Skip to content

Commit

Permalink
[SYNCOPE-1860] Switching to JAR executables
Browse files Browse the repository at this point in the history
  • Loading branch information
ilgrosso committed Feb 1, 2025
1 parent 0ec8c9d commit d580900
Show file tree
Hide file tree
Showing 17 changed files with 54 additions and 102 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -30,7 +30,11 @@ under the License.
<name>Apache Syncope sample project - Console</name>
<groupId>${groupId}</groupId>
<artifactId>${artifactId}</artifactId>
<packaging>war</packaging>
<packaging>${packaging}</packaging>

<properties>
<packaging>war</packaging>
</properties>

<dependencies>
<dependency>
Expand Down Expand Up @@ -123,6 +127,10 @@ under the License.
<profile>
<id>standalone</id>

<properties>
<packaging>jar</packaging>
</properties>

<dependencies>
<dependency>
<groupId>org.springframework.boot</groupId>
Expand Down
12 changes: 10 additions & 2 deletions archetype/src/main/resources/archetype-resources/core/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -30,7 +30,11 @@ under the License.
<name>Apache Syncope sample project - Core</name>
<groupId>${groupId}</groupId>
<artifactId>${artifactId}</artifactId>
<packaging>war</packaging>
<packaging>${packaging}</packaging>

<properties>
<packaging>war</packaging>
</properties>

<dependencies>
<dependency>
Expand Down Expand Up @@ -169,7 +173,11 @@ under the License.

<profile>
<id>standalone</id>


<properties>
<packaging>jar</packaging>
</properties>

<dependencies>
<dependency>
<groupId>org.springframework.boot</groupId>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -30,7 +30,11 @@ under the License.
<name>Apache Syncope sample project - Enduser</name>
<groupId>${groupId}</groupId>
<artifactId>${artifactId}</artifactId>
<packaging>war</packaging>
<packaging>${packaging}</packaging>

<properties>
<packaging>war</packaging>
</properties>

<dependencies>
<dependency>
Expand Down Expand Up @@ -150,6 +154,10 @@ under the License.
<profile>
<id>standalone</id>

<properties>
<packaging>jar</packaging>
</properties>

<dependencies>
<dependency>
<groupId>org.springframework.boot</groupId>
Expand Down
10 changes: 9 additions & 1 deletion archetype/src/main/resources/archetype-resources/wa/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -30,7 +30,11 @@ under the License.
<name>Apache Syncope sample project - WA</name>
<groupId>${groupId}</groupId>
<artifactId>${artifactId}</artifactId>
<packaging>war</packaging>
<packaging>${packaging}</packaging>

<properties>
<packaging>war</packaging>
</properties>

<dependencyManagement>
<dependencies>
Expand Down Expand Up @@ -142,6 +146,10 @@ under the License.
<profile>
<id>standalone</id>

<properties>
<packaging>jar</packaging>
</properties>

<dependencies>
<dependency>
<groupId>org.springframework.boot</groupId>
Expand Down
22 changes: 1 addition & 21 deletions docker/console/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -31,7 +31,7 @@ under the License.
<description>Apache Syncope Docker Console</description>
<groupId>org.apache.syncope</groupId>
<artifactId>syncope-docker-console</artifactId>
<packaging>war</packaging>
<packaging>jar</packaging>

<properties>
<rootpom.basedir>${basedir}/../..</rootpom.basedir>
Expand Down Expand Up @@ -92,26 +92,6 @@ under the License.

<build>
<plugins>
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-war-plugin</artifactId>
<inherited>false</inherited>
<configuration>
<webXml>${basedir}/../../fit/console-reference/src/main/webapp/WEB-INF/web.xml</webXml>
<webResources>
<resource>
<directory>${basedir}</directory>
<targetPath>META-INF</targetPath>
<includes>
<include>LICENSE</include>
<include>NOTICE</include>
</includes>
</resource>
</webResources>
<outputDirectory>${project.build.outputDirectory}</outputDirectory>
</configuration>
</plugin>

<plugin>
<groupId>org.springframework.boot</groupId>
<artifactId>spring-boot-maven-plugin</artifactId>
Expand Down
2 changes: 1 addition & 1 deletion docker/console/src/main/resources/Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -29,7 +29,7 @@ RUN mkdir /opt/syncope/log
COPY *.properties /opt/syncope/conf/
COPY log4j2.xml /opt/syncope/conf/

COPY syncope-docker-console-*war /opt/syncope/lib/syncope-console.war
COPY syncope-docker-console-*jar /opt/syncope/lib/syncope-console.jar

ENV SPRING_PROFILES_ACTIVE=docker
ENV LOADER_PATH="/opt/syncope/conf,/opt/syncope/lib"
Expand Down
2 changes: 1 addition & 1 deletion docker/console/src/main/resources/startup.sh
Original file line number Diff line number Diff line change
Expand Up @@ -17,4 +17,4 @@
# specific language governing permissions and limitations
# under the License.

java $JAVA_OPTS -jar /opt/syncope/lib/syncope-console.war
java $JAVA_OPTS -jar /opt/syncope/lib/syncope-console.jar
30 changes: 5 additions & 25 deletions docker/core/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -31,7 +31,7 @@ under the License.
<description>Apache Syncope Docker Core</description>
<groupId>org.apache.syncope</groupId>
<artifactId>syncope-docker-core</artifactId>
<packaging>war</packaging>
<packaging>jar</packaging>

<properties>
<rootpom.basedir>${basedir}/../..</rootpom.basedir>
Expand Down Expand Up @@ -195,26 +195,6 @@ under the License.
</executions>
</plugin>

<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-war-plugin</artifactId>
<inherited>false</inherited>
<configuration>
<webXml>${basedir}/../../fit/core-reference/src/main/webapp/WEB-INF/web.xml</webXml>
<webResources>
<resource>
<directory>${basedir}</directory>
<targetPath>META-INF</targetPath>
<includes>
<include>LICENSE</include>
<include>NOTICE</include>
</includes>
</resource>
</webResources>
<outputDirectory>${project.build.outputDirectory}/lib</outputDirectory>
</configuration>
</plugin>

<plugin>
<groupId>org.springframework.boot</groupId>
<artifactId>spring-boot-maven-plugin</artifactId>
Expand Down Expand Up @@ -245,10 +225,10 @@ under the License.
<build>
<dockerFileDir>${project.build.outputDirectory}</dockerFileDir>
<buildx>
<platforms>
<platform>linux/amd64</platform>
<platform>linux/arm64</platform>
</platforms>
<platforms>
<platform>linux/amd64</platform>
<platform>linux/arm64</platform>
</platforms>
</buildx>
</build>
</image>
Expand Down
2 changes: 1 addition & 1 deletion docker/core/src/main/resources/Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -36,7 +36,7 @@ COPY bundles/*.jar /opt/syncope/bundles/
COPY lib/*.jar /opt/syncope/lib/
COPY jpa-json/*.jar /opt/syncope/jpa-json/

COPY lib/syncope-docker-core-*war /opt/syncope/lib/syncope.war
COPY lib/syncope-docker-core-*jar /opt/syncope/lib/syncope.jar

ENV SPRING_PROFILES_ACTIVE=docker
ENV LOADER_PATH="/opt/syncope/conf,/opt/syncope/lib"
Expand Down
2 changes: 1 addition & 1 deletion docker/core/src/main/resources/startup.sh
Original file line number Diff line number Diff line change
Expand Up @@ -17,4 +17,4 @@
# specific language governing permissions and limitations
# under the License.

java $JAVA_OPTS -jar /opt/syncope/lib/syncope.war
java $JAVA_OPTS -jar /opt/syncope/lib/syncope.jar
22 changes: 1 addition & 21 deletions docker/enduser/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -31,7 +31,7 @@ under the License.
<description>Apache Syncope Docker Enduser</description>
<groupId>org.apache.syncope</groupId>
<artifactId>syncope-docker-enduser</artifactId>
<packaging>war</packaging>
<packaging>jar</packaging>

<properties>
<rootpom.basedir>${basedir}/../..</rootpom.basedir>
Expand Down Expand Up @@ -81,26 +81,6 @@ under the License.

<build>
<plugins>
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-war-plugin</artifactId>
<inherited>false</inherited>
<configuration>
<webXml>${basedir}/../../fit/enduser-reference/src/main/webapp/WEB-INF/web.xml</webXml>
<webResources>
<resource>
<directory>${basedir}</directory>
<targetPath>META-INF</targetPath>
<includes>
<include>LICENSE</include>
<include>NOTICE</include>
</includes>
</resource>
</webResources>
<outputDirectory>${project.build.outputDirectory}</outputDirectory>
</configuration>
</plugin>

<plugin>
<groupId>org.springframework.boot</groupId>
<artifactId>spring-boot-maven-plugin</artifactId>
Expand Down
2 changes: 1 addition & 1 deletion docker/enduser/src/main/resources/Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -30,7 +30,7 @@ COPY *.properties /opt/syncope/conf/
COPY *.json /opt/syncope/conf/
COPY log4j2.xml /opt/syncope/conf/

COPY syncope-docker-enduser-*war /opt/syncope/lib/syncope-enduser.war
COPY syncope-docker-enduser-*jar /opt/syncope/lib/syncope-enduser.jar

ENV SPRING_PROFILES_ACTIVE=docker
ENV LOADER_PATH="/opt/syncope/conf,/opt/syncope/lib"
Expand Down
2 changes: 1 addition & 1 deletion docker/enduser/src/main/resources/startup.sh
Original file line number Diff line number Diff line change
Expand Up @@ -17,4 +17,4 @@
# specific language governing permissions and limitations
# under the License.

java $JAVA_OPTS -jar /opt/syncope/lib/syncope-enduser.war
java $JAVA_OPTS -jar /opt/syncope/lib/syncope-enduser.jar
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,7 @@

services:
keymaster:
image: zookeeper:3.8.1
image: zookeeper:3.9.3
restart: always

db:
Expand Down
22 changes: 1 addition & 21 deletions docker/wa/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -31,7 +31,7 @@ under the License.
<description>Apache Syncope Docker WA</description>
<groupId>org.apache.syncope</groupId>
<artifactId>syncope-docker-wa</artifactId>
<packaging>war</packaging>
<packaging>jar</packaging>

<dependencyManagement>
<dependencies>
Expand Down Expand Up @@ -75,26 +75,6 @@ under the License.

<build>
<plugins>
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-war-plugin</artifactId>
<inherited>false</inherited>
<configuration>
<webXml>${basedir}/../../fit/wa-reference/src/main/webapp/WEB-INF/web.xml</webXml>
<webResources>
<resource>
<directory>${basedir}</directory>
<targetPath>META-INF</targetPath>
<includes>
<include>LICENSE</include>
<include>NOTICE</include>
</includes>
</resource>
</webResources>
<outputDirectory>${project.build.outputDirectory}</outputDirectory>
</configuration>
</plugin>

<plugin>
<groupId>org.springframework.boot</groupId>
<artifactId>spring-boot-maven-plugin</artifactId>
Expand Down
2 changes: 1 addition & 1 deletion docker/wa/src/main/resources/Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -29,7 +29,7 @@ RUN mkdir /opt/syncope/log
COPY *.properties /opt/syncope/conf/
COPY log4j2.xml /opt/syncope/conf/

COPY syncope-docker-wa-*war /opt/syncope/lib/syncope-wa.war
COPY syncope-docker-wa-*jar /opt/syncope/lib/syncope-wa.jar

ENV SPRING_PROFILES_ACTIVE=docker
ENV LOADER_PATH="/opt/syncope/conf,/opt/syncope/lib"
Expand Down
2 changes: 1 addition & 1 deletion docker/wa/src/main/resources/startup.sh
Original file line number Diff line number Diff line change
Expand Up @@ -17,4 +17,4 @@
# specific language governing permissions and limitations
# under the License.

java $JAVA_OPTS -jar /opt/syncope/lib/syncope-wa.war
java $JAVA_OPTS -jar /opt/syncope/lib/syncope-wa.jar

0 comments on commit d580900

Please sign in to comment.