From dfa74cfe8502cef0e4a0cbf98ea6818223d84fdd Mon Sep 17 00:00:00 2001 From: OZGCloud <ozgcloud@mgm-tp.com> Date: Thu, 15 Dec 2022 16:11:16 +0100 Subject: [PATCH] OZG-3284 control image building by maven profile --- Jenkinsfile | 2 +- .../formcycle-adapter-impl/pom.xml | 11 +++++++- formsolutions-adapter/pom.xml | 26 +++++++++++++++--- intelliform-adapter/pom.xml | 27 ++++++++++++++++--- 4 files changed, 58 insertions(+), 8 deletions(-) diff --git a/Jenkinsfile b/Jenkinsfile index bffcadebc..54ab5dde0 100644 --- a/Jenkinsfile +++ b/Jenkinsfile @@ -62,7 +62,7 @@ pipeline { } configFileProvider([configFile(fileId: 'maven-settings', variable: 'MAVEN_SETTINGS')]) { sh 'mvn --version' - sh 'mvn -s $MAVEN_SETTINGS clean install spring-boot:build-image -Dmaven.wagon.http.retryHandler.count=3' + sh 'mvn -s $MAVEN_SETTINGS -P ci-build clean install -Dmaven.wagon.http.retryHandler.count=3' script { try { diff --git a/formcycle-adapter/formcycle-adapter-impl/pom.xml b/formcycle-adapter/formcycle-adapter-impl/pom.xml index 39ac7f943..4d17b98b9 100644 --- a/formcycle-adapter/formcycle-adapter-impl/pom.xml +++ b/formcycle-adapter/formcycle-adapter-impl/pom.xml @@ -30,6 +30,15 @@ <groupId>formcycle-adapter-impl</groupId> <artifactId>formcycle-adapter-impl</artifactId> <version>0.0.1-SNAPSHOT</version> - + <name>EM - Formcycle Adapter - Implementation</name> + + <build> + <plugins> + <plugin> + <groupId>org.springframework.boot</groupId> + <artifactId>spring-boot-maven-plugin</artifactId> + </plugin> + </plugins> + </build> </project> \ No newline at end of file diff --git a/formsolutions-adapter/pom.xml b/formsolutions-adapter/pom.xml index 89959d74e..12a71cad0 100644 --- a/formsolutions-adapter/pom.xml +++ b/formsolutions-adapter/pom.xml @@ -23,9 +23,7 @@ unter der Lizenz sind dem Lizenztext zu entnehmen. --> -<project xmlns="http://maven.apache.org/POM/4.0.0" - xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" - xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 https://maven.apache.org/xsd/maven-4.0.0.xsd"> +<project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 https://maven.apache.org/xsd/maven-4.0.0.xsd"> <modelVersion>4.0.0</modelVersion> <parent> @@ -188,4 +186,26 @@ </plugins> </build> + <profiles> + <profile> + <id>ci-build</id> + <build> + <plugins> + <plugin> + <groupId>org.springframework.boot</groupId> + <artifactId>spring-boot-maven-plugin</artifactId> + <executions> + <execution> + <id>build-image</id> + <phase>install</phase> + <goals> + <goal>build-image</goal> + </goals> + </execution> + </executions> + </plugin> + </plugins> + </build> + </profile> + </profiles> </project> \ No newline at end of file diff --git a/intelliform-adapter/pom.xml b/intelliform-adapter/pom.xml index cd570ef64..02d72bd30 100644 --- a/intelliform-adapter/pom.xml +++ b/intelliform-adapter/pom.xml @@ -24,9 +24,7 @@ unter der Lizenz sind dem Lizenztext zu entnehmen. --> -<project xmlns="http://maven.apache.org/POM/4.0.0" - xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" - xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 https://maven.apache.org/xsd/maven-4.0.0.xsd"> +<project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 https://maven.apache.org/xsd/maven-4.0.0.xsd"> <modelVersion>4.0.0</modelVersion> @@ -228,4 +226,27 @@ </plugins> </build> + <profiles> + <profile> + <id>ci-build</id> + <build> + <plugins> + <plugin> + <groupId>org.springframework.boot</groupId> + <artifactId>spring-boot-maven-plugin</artifactId> + <executions> + <execution> + <id>build-image</id> + <phase>install</phase> + <goals> + <goal>build-image</goal> + </goals> + </execution> + </executions> + </plugin> + </plugins> + </build> + </profile> + </profiles> + </project> -- GitLab