You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@hop.apache.org by ha...@apache.org on 2023/04/28 14:02:21 UTC

[hop] branch master updated: Simplify the Hop Web image including beam, fixes #2884

This is an automated email from the ASF dual-hosted git repository.

hansva pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/hop.git


The following commit(s) were added to refs/heads/master by this push:
     new 62d271215b Simplify the Hop Web image including beam, fixes #2884
     new d289b88ccf Merge pull request #2885 from hansva/master
62d271215b is described below

commit 62d271215b5295dad1d89c1800c56bdacee6b061
Author: Hans Van Akelyen <ha...@gmail.com>
AuthorDate: Fri Apr 28 16:00:05 2023 +0200

    Simplify the Hop Web image including beam, fixes #2884
---
 Jenkinsfile                  |  2 +-
 docker/Dockerfile.web-fatjar | 46 ++------------------------------------------
 2 files changed, 3 insertions(+), 45 deletions(-)

diff --git a/Jenkinsfile b/Jenkinsfile
index f628272df1..08ba911807 100644
--- a/Jenkinsfile
+++ b/Jenkinsfile
@@ -162,7 +162,7 @@ pipeline {
                     //Base docker image
                     sh "docker buildx build --platform linux/amd64,linux/arm64 . -f docker/Dockerfile.web -t ${DOCKER_REPO_WEB}:${env.POM_VERSION} -t ${DOCKER_REPO_WEB}:Development --push"
                     //Image including fat-jar
-                    sh "docker buildx build --platform linux/amd64,linux/arm64 . -f docker/Dockerfile.web-fatjar -t ${DOCKER_REPO_WEB}:${env.POM_VERSION}-beam -t ${DOCKER_REPO_WEB}:Development-beam --push"
+                    sh "docker buildx build  --build-arg HOP_WEB_VERSION=Development --platform linux/amd64,linux/arm64 . -f docker/Dockerfile.web-fatjar -t ${DOCKER_REPO_WEB}:${env.POM_VERSION}-beam -t ${DOCKER_REPO_WEB}:Development-beam --push"
                     sh "docker buildx rm hop"
                   }
             }
diff --git a/docker/Dockerfile.web-fatjar b/docker/Dockerfile.web-fatjar
index 5f093c8ecd..968747c634 100644
--- a/docker/Dockerfile.web-fatjar
+++ b/docker/Dockerfile.web-fatjar
@@ -16,52 +16,10 @@
 # under the License.
 #
 
-FROM tomcat:9-jdk11-openjdk
-LABEL maintainer="Apache Hop Team"
-ENV HOP_AES_ENCODER_KEY=""
-ENV HOP_AUDIT_FOLDER="${CATALINA_HOME}/webapps/ROOT/audit"
-ENV HOP_CONFIG_FOLDER="${CATALINA_HOME}/webapps/ROOT/config"
-# specify the hop log level
-ENV HOP_LOG_LEVEL="Basic"
-# any JRE settings you want to pass on
-# The “-XX:+AggressiveHeap” tells the container to use all memory assigned to the container. 
-# this removed the need to calculate the necessary heap Xmx
-ENV HOP_OPTIONS="-XX:+AggressiveHeap"
-ENV HOP_PASSWORD_ENCODER_PLUGIN="Hop"
-ENV HOP_PLUGIN_BASE_FOLDERS="plugins"
-# path to jdbc drivers
-ENV HOP_SHARED_JDBC_FOLDER=""
-ENV HOP_WEB_THEME="light"
-ENV HOP_GUI_ZOOM_FACTOR=1.0
-
-# Set TOMCAT start variables
-ENV CATALINA_OPTS='${HOP_OPTIONS} \
-  -DHOP_AES_ENCODER_KEY="${HOP_AES_ENCODER_KEY}" \
-  -DHOP_AUDIT_FOLDER="${HOP_AUDIT_FOLDER}" \
-  -DHOP_CONFIG_FOLDER="${HOP_CONFIG_FOLDER}" \
-  -DHOP_LOG_LEVEL="${HOP_LOG_LEVEL}" \
-  -DHOP_PASSWORD_ENCODER_PLUGIN="${HOP_PASSWORD_ENCODER_PLUGIN}" \
-  -DHOP_PLUGIN_BASE_FOLDERS="${HOP_PLUGIN_BASE_FOLDERS}" \
-  -DHOP_SHARED_JDBC_FOLDER="${HOP_SHARED_JDBC_FOLDER}" \
-  -DHOP_WEB_THEME="${HOP_WEB_THEME}" \
-  -DHOP_GUI_ZOOM_FACTOR="${HOP_GUI_ZOOM_FACTOR}"'
-
-# Cleanup and create folder
-RUN rm -rf webapps/* \
-    && mkdir "${CATALINA_HOME}"/webapps/ROOT
-
-# Copy resources
-COPY ./assemblies/web/target/webapp/ "${CATALINA_HOME}"/webapps/ROOT/
-COPY ./assemblies/plugins/dist/target/plugins "${CATALINA_HOME}"/plugins
+ARG HOP_WEB_VERSION=latest
+FROM apache/hop-web:${HOP_WEB_VERSION}
 
 # Copy the fatjar to hop-web
 COPY ./assemblies/client/target/hop-fatjar.jar /root/hop-fatjar.jar
 
-COPY ./docker/resources/run-web.sh /tmp/
-
-# Fix hop-config.json
-RUN sed -i 's/config\/projects/${HOP_CONFIG_FOLDER}\/projects/g' "${CATALINA_HOME}"/webapps/ROOT/config/hop-config.json
-
-RUN mkdir -p "$CATALINA_HOME"/lib/swt/linux/x86_64
-
 CMD ["/bin/bash", "/tmp/run-web.sh"]