Replace custom base image in sparky-be 28/140528/1 2.0.7
authorFiete Ostkamp <Fiete.Ostkamp@telekom.de>
Thu, 20 Mar 2025 08:54:12 +0000 (09:54 +0100)
committerFiete Ostkamp <Fiete.Ostkamp@telekom.de>
Thu, 20 Mar 2025 08:55:57 +0000 (09:55 +0100)
- use eclipse-temurin:11-jre-alpine base image instead of
  aai-common image

Issue-ID: AAI-4146
Change-Id: I4d3b4ed2359a7eb975a58f20ce21c2bc5d0bb005
Signed-off-by: Fiete Ostkamp <Fiete.Ostkamp@telekom.de>
pom.xml
sparkybe-onap-application/pom.xml
sparkybe-onap-application/src/main/docker/Dockerfile
sparkybe-onap-application/src/main/scripts/start.sh [changed mode: 0644->0755]
sparkybe-onap-service/pom.xml
version.properties

diff --git a/pom.xml b/pom.xml
index 6d4fc72..a5f8c2c 100644 (file)
--- a/pom.xml
+++ b/pom.xml
@@ -12,7 +12,7 @@
 
        <groupId>org.onap.aai</groupId>
        <artifactId>sparky-be</artifactId>
-       <version>2.0.6-SNAPSHOT</version>
+       <version>2.0.7-SNAPSHOT</version>
        <packaging>pom</packaging>
        <name>aai-sparky-be</name>
 
index 5e21ea7..e8a5d05 100644 (file)
@@ -5,12 +5,12 @@
        <parent>
          <groupId>org.onap.aai</groupId>
          <artifactId>sparky-be</artifactId>
-         <version>2.0.6-SNAPSHOT</version>
+         <version>2.0.7-SNAPSHOT</version>
        </parent>
 
        <groupId>org.onap.aai.sparky-be</groupId>
        <artifactId>sparkybe-onap-application</artifactId>
-       <version>2.0.6-SNAPSHOT</version>
+       <version>2.0.7-SNAPSHOT</version>
        <packaging>jar</packaging>
 
     <properties>
@@ -35,8 +35,6 @@
         <aai.build.directory>${project.build.directory}/${project.artifactId}-build/
         </aai.build.directory>
         <aai.docker.namespace>onap</aai.docker.namespace>
-        <aai.base.image>alpine</aai.base.image>
-        <aai.base.image.version>1.13.2</aai.base.image.version>
         <jacoco.line.coverage.limit>0.10</jacoco.line.coverage.limit>
         <!-- This will be used for the docker images as the default format of maven build has issues -->
         <maven.build.timestamp.format>yyyyMMdd'T'HHmmss'Z'</maven.build.timestamp.format>
                         <groupId>org.codehaus.groovy.maven</groupId>
                         <artifactId>gmaven-plugin</artifactId>
                         <version>1.0</version>
-                        <executions>
-                            <execution>
-                                <phase>pre-clean</phase>
-                                <goals>
-                                    <goal>execute</goal>
-                                </goals>
-                                <configuration>
-                                    <source>
-                                        def userAaiBaseImage = session.userProperties['aai.base.image']
-                                        def userAaiCommonVersion = session.userProperties['aai.base.image.version']
-                                        if (userAaiCommonVersion != null) {
-                                            project.properties['aai.base.image.version'] = userAaiCommonVersion
-                                        }
-                                        if (userAaiBaseImage != null) {
-                                            project.properties['aai.base.image'] = userAaiBaseImage
-                                        }
-                                        log.info 'Base image flavour: ' + project.properties['aai.base.image']
-                                        log.info 'Base image version: ' + project.properties['aai.base.image.version']
-                                    </source>
-                                </configuration>
-                            </execution>
-                        </executions>
                     </plugin>
                     <plugin>
                         <groupId>io.fabric8</groupId>
index 6f95de0..39c9e91 100644 (file)
@@ -1,24 +1,13 @@
-FROM @aai.docker.namespace@/aai-common-@aai.base.image@:@aai.base.image.version@
-
-ARG MICRO_HOME=/opt/app/sparky
-ARG BIN_HOME=$MICRO_HOME/bin
-ARG UI_LOGS=/var/log/onap/AAI-UI
-
-USER root
+FROM eclipse-temurin:11-jre-alpine
+USER nobody
 
+ENV MICRO_HOME=/opt/app/sparky
 WORKDIR $MICRO_HOME
 
-COPY --chown=aaiadmin:aaiadmin /maven/sparkybe-onap-application/ .
-
-# Build up the deployment folder structure
-RUN mkdir -p $MICRO_HOME $MICRO_HOME/logs $UI_LOGS && \
-    chown -R aaiadmin:aaiadmin $MICRO_HOME/logs $UI_LOGS && \
-    chmod 755 $BIN_HOME/* && \
-    ln -snf /logs $MICRO_HOME/logs
+COPY --chown=nobody:nobody /maven/sparkybe-onap-application/ .
 
-USER aaiadmin
 
 EXPOSE 8000 8000
 EXPOSE 9517 9517
 
-CMD ["/opt/app/sparky/bin/start.sh"]
+CMD ["/bin/sh", "/opt/app/sparky/bin/start.sh"]
old mode 100644 (file)
new mode 100755 (executable)
index 7faae8d..c478439
@@ -5,8 +5,6 @@ CONFIG_HOME=${APP_HOME}/config
 
 PROPS="-DAPP_HOME=${APP_HOME} -DCONFIG_HOME=${CONFIG_HOME} -Dlogging.config=${CONFIG_HOME}/logging/logback.xml"
 
-find ${MICRO_HOME}  -name "*.sh" -exec chmod +x {} +
-
 JAVA_CMD="exec java";
 JAR_CMD="exec jar";
 
index b6a6394..e872746 100644 (file)
@@ -4,12 +4,12 @@
   <parent>
          <groupId>org.onap.aai</groupId>
          <artifactId>sparky-be</artifactId>
-         <version>2.0.6-SNAPSHOT</version>
+         <version>2.0.7-SNAPSHOT</version>
        </parent>
 
        <groupId>org.onap.aai.sparky-be</groupId>
        <artifactId>sparkybe-onap-service</artifactId>
-       <version>2.0.6-SNAPSHOT</version>
+       <version>2.0.7-SNAPSHOT</version>
        <packaging>jar</packaging>
 
        <properties>
index 640b101..d4e7f68 100644 (file)
@@ -4,7 +4,7 @@
 
 major=2
 minor=0
-patch=6
+patch=7
 
 base_version=${major}.${minor}.${patch}