From a0310b4894853d19ded120bf63ff2b89332b8c6d Mon Sep 17 00:00:00 2001 From: "silke.schmid" Date: Tue, 28 May 2024 13:04:44 +0200 Subject: [PATCH 01/16] make PDI runnable after unpacking it --- Dockerfile | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) diff --git a/Dockerfile b/Dockerfile index aaa9910..7aec12e 100644 --- a/Dockerfile +++ b/Dockerfile @@ -20,6 +20,10 @@ RUN curl ${PENTAHO_URL} -o $HOME/pdi-ce-${PDI_VERSION}.zip RUN cd $PENTAHO_INSTALL && jar -xvf $HOME/pdi-ce-${PDI_VERSION}.zip + # Make PDI runnable + RUN chmod 775 $PENTAHO_INSTALL/data-integration + RUN chmod 755 $PENTAHO_INSTALL/data-integration/*.sh + ################################################################################################## # Second layer: Here is where we create the final image # ################################################################################################## @@ -48,9 +52,6 @@ # Copy Pentaho PDI from layer install_unpack to this layer COPY --from=install_unpack ${PENTAHO_INSTALL}/data-integration/ ${KETTLE_HOME}/ - RUN chmod 775 ${KETTLE_HOME} - RUN chmod 755 ${KETTLE_HOME}/*.sh - # Start Carte Server RUN cd ${KETTLE_HOME} CMD ${KETTLE_HOME}/carte.sh ${HOSTNAME} ${CARTE_PORT} \ No newline at end of file From ab20d64e8573755d45cec69d671739f07b94f1b1 Mon Sep 17 00:00:00 2001 From: "silke.schmid" Date: Tue, 28 May 2024 13:07:59 +0200 Subject: [PATCH 02/16] Action build and test runs on any branch --- .github/workflows/build.yaml | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/.github/workflows/build.yaml b/.github/workflows/build.yaml index e821433..bf3c6cd 100644 --- a/.github/workflows/build.yaml +++ b/.github/workflows/build.yaml @@ -2,8 +2,7 @@ name: build and test on: push: - branches: ["main"] - pull_request: + pull_request: branches: ["main"] jobs: From 09f7057ac83c7699dca3cce3d1f5bf4db5c49528 Mon Sep 17 00:00:00 2001 From: "silke.schmid" Date: Tue, 28 May 2024 13:14:34 +0200 Subject: [PATCH 03/16] remove commented line --- .github/workflows/build.yaml | 1 - 1 file changed, 1 deletion(-) diff --git a/.github/workflows/build.yaml b/.github/workflows/build.yaml index bf3c6cd..cfcd189 100644 --- a/.github/workflows/build.yaml +++ b/.github/workflows/build.yaml @@ -31,7 +31,6 @@ jobs: - name: Build image uses: docker/build-push-action@v5 with: -# context: ./pentaho-carte push: false # tags: itatm/pentaho-carte:${{ env.GITHUB_REF_NAME_SLUG }} tags: itatm/pentaho-carte:latest \ No newline at end of file From 98594ff479a348064397cd780e42e485448fccdc Mon Sep 17 00:00:00 2001 From: "silke.schmid" Date: Tue, 28 May 2024 13:20:45 +0200 Subject: [PATCH 04/16] removed .idea directory --- .idea/.gitignore | 3 --- .idea/misc.xml | 6 ------ .idea/modules.xml | 8 -------- .idea/penthao-carte.iml | 9 --------- .idea/vcs.xml | 6 ------ .idea/workspace.xml | 43 +++++++++++++++++++++++++++++++++++++++++ 6 files changed, 43 insertions(+), 32 deletions(-) delete mode 100644 .idea/.gitignore delete mode 100644 .idea/misc.xml delete mode 100644 .idea/modules.xml delete mode 100644 .idea/penthao-carte.iml delete mode 100644 .idea/vcs.xml create mode 100644 .idea/workspace.xml diff --git a/.idea/.gitignore b/.idea/.gitignore deleted file mode 100644 index 26d3352..0000000 --- a/.idea/.gitignore +++ /dev/null @@ -1,3 +0,0 @@ -# Default ignored files -/shelf/ -/workspace.xml diff --git a/.idea/misc.xml b/.idea/misc.xml deleted file mode 100644 index 07115cd..0000000 --- a/.idea/misc.xml +++ /dev/null @@ -1,6 +0,0 @@ - - - - - - \ No newline at end of file diff --git a/.idea/modules.xml b/.idea/modules.xml deleted file mode 100644 index 0e8242b..0000000 --- a/.idea/modules.xml +++ /dev/null @@ -1,8 +0,0 @@ - - - - - - - - \ No newline at end of file diff --git a/.idea/penthao-carte.iml b/.idea/penthao-carte.iml deleted file mode 100644 index d6ebd48..0000000 --- a/.idea/penthao-carte.iml +++ /dev/null @@ -1,9 +0,0 @@ - - - - - - - - - \ No newline at end of file diff --git a/.idea/vcs.xml b/.idea/vcs.xml deleted file mode 100644 index 35eb1dd..0000000 --- a/.idea/vcs.xml +++ /dev/null @@ -1,6 +0,0 @@ - - - - - - \ No newline at end of file diff --git a/.idea/workspace.xml b/.idea/workspace.xml new file mode 100644 index 0000000..500dfde --- /dev/null +++ b/.idea/workspace.xml @@ -0,0 +1,43 @@ + + + + + + + + + + { + "associatedIndex": 2 +} + + + + + + + + + 1716296702148 + + + + \ No newline at end of file From 032351e34e2b671f51cfb01ad8daf348d1fe14c2 Mon Sep 17 00:00:00 2001 From: "silke.schmid" Date: Tue, 28 May 2024 13:21:24 +0200 Subject: [PATCH 05/16] removed .idea directory --- .idea/workspace.xml | 43 ------------------------------------------- 1 file changed, 43 deletions(-) delete mode 100644 .idea/workspace.xml diff --git a/.idea/workspace.xml b/.idea/workspace.xml deleted file mode 100644 index 500dfde..0000000 --- a/.idea/workspace.xml +++ /dev/null @@ -1,43 +0,0 @@ - - - - - - - - - - { - "associatedIndex": 2 -} - - - - - - - - - 1716296702148 - - - - \ No newline at end of file From 48f140e9c922da23f1689fe09a8559c77cd83ea9 Mon Sep 17 00:00:00 2001 From: "silke.schmid" Date: Tue, 28 May 2024 13:24:52 +0200 Subject: [PATCH 06/16] .gitignore --- .gitignore | 19 +++++++++++++++++++ 1 file changed, 19 insertions(+) create mode 100644 .gitignore diff --git a/.gitignore b/.gitignore new file mode 100644 index 0000000..f4bcca0 --- /dev/null +++ b/.gitignore @@ -0,0 +1,19 @@ +# Covers Eclipse specific: +.settings/ +.classpath +.project + +# Covers JetBrains IDEs: IntelliJ, RubyMine, PhpStorm, AppCode, PyCharm, CLion, Android Studio and WebStorm +.idea +*.iml + +# Covers Netbeans: +**/nbproject/private/ +**/nbproject/Makefile-*.mk +**/nbproject/Package-*.bash +build/ +nbbuild/ +dist/ +nbdist/ +.nb-gradle/ + From c5ac24e8992bd28882ca4cb06efcb830e84e0607 Mon Sep 17 00:00:00 2001 From: "silke.schmid" Date: Tue, 28 May 2024 15:15:18 +0200 Subject: [PATCH 07/16] create_release --- .github/workflows/release-image.yaml | 18 ++++++++++-------- 1 file changed, 10 insertions(+), 8 deletions(-) diff --git a/.github/workflows/release-image.yaml b/.github/workflows/release-image.yaml index 7226d9c..46789c1 100644 --- a/.github/workflows/release-image.yaml +++ b/.github/workflows/release-image.yaml @@ -31,6 +31,7 @@ jobs: - name: Log in to the Container registry uses: docker/login-action@v3 with: + ref: ${{ inputs.branch }} registry: ${{ env.REGISTRY }} username: ${{ github.actor }} password: ${{ secrets.GITHUB_TOKEN }} @@ -60,11 +61,12 @@ jobs: # subject-digest: ${{ steps.push.outputs.digest }} # push-to-registry: true - - name: Create GitHub Release - id: create_release - uses: softprops/action-gh-release@v2 - with: - tag_name: ${{ github.event.inputs.release-tag }} - draft: false - prerelease: false - generate_release_notes: true \ No newline at end of file +# - name: Create GitHub Release +# id: create_release +# if: inputs.do_release == 'true' +# uses: softprops/action-gh-release@v2 +# with: +# tag_name: ${{ github.event.inputs.release-tag }} +# draft: false +# prerelease: false +# generate_release_notes: true \ No newline at end of file From 1ca01d6b1aa3e771bc7cd4d17b8202e1a8b352f4 Mon Sep 17 00:00:00 2001 From: "silke.schmid" Date: Tue, 28 May 2024 16:56:30 +0200 Subject: [PATCH 08/16] COPY command with --chmod flag --- Dockerfile | 9 ++++----- 1 file changed, 4 insertions(+), 5 deletions(-) diff --git a/Dockerfile b/Dockerfile index 7aec12e..2b69555 100644 --- a/Dockerfile +++ b/Dockerfile @@ -20,10 +20,6 @@ RUN curl ${PENTAHO_URL} -o $HOME/pdi-ce-${PDI_VERSION}.zip RUN cd $PENTAHO_INSTALL && jar -xvf $HOME/pdi-ce-${PDI_VERSION}.zip - # Make PDI runnable - RUN chmod 775 $PENTAHO_INSTALL/data-integration - RUN chmod 755 $PENTAHO_INSTALL/data-integration/*.sh - ################################################################################################## # Second layer: Here is where we create the final image # ################################################################################################## @@ -50,7 +46,10 @@ RUN chmod 775 ${PENTAHO_HOME} # Copy Pentaho PDI from layer install_unpack to this layer - COPY --from=install_unpack ${PENTAHO_INSTALL}/data-integration/ ${KETTLE_HOME}/ + COPY --from=install_unpack --chmod=775 ${PENTAHO_INSTALL}/data-integration/ ${KETTLE_HOME}/ + + # Make PDI runnable + RUN chmod 755 $PENTAHO_INSTALL/data-integration/*.sh # Start Carte Server RUN cd ${KETTLE_HOME} From 14f31705209024af720020f7f359147a977ac4e1 Mon Sep 17 00:00:00 2001 From: "silke.schmid" Date: Tue, 28 May 2024 17:02:03 +0200 Subject: [PATCH 09/16] RUN chmod 755 ./c/b/*.sh --- Dockerfile | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Dockerfile b/Dockerfile index 2b69555..38b9639 100644 --- a/Dockerfile +++ b/Dockerfile @@ -49,7 +49,7 @@ COPY --from=install_unpack --chmod=775 ${PENTAHO_INSTALL}/data-integration/ ${KETTLE_HOME}/ # Make PDI runnable - RUN chmod 755 $PENTAHO_INSTALL/data-integration/*.sh + RUN chmod 755 ${KETTLE_HOME}/*.sh # Start Carte Server RUN cd ${KETTLE_HOME} From 60dde4629d58336a95a271acb4f6dc2f6c2c35e7 Mon Sep 17 00:00:00 2001 From: "silke.schmid" Date: Wed, 29 May 2024 09:52:52 +0200 Subject: [PATCH 10/16] Create KETTLE_HOME before COPY PDI to image layer --- Dockerfile | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/Dockerfile b/Dockerfile index 38b9639..23c00d5 100644 --- a/Dockerfile +++ b/Dockerfile @@ -45,6 +45,10 @@ RUN mkdir ${PENTAHO_HOME} RUN chmod 775 ${PENTAHO_HOME} + # Create PENTAHO_HOME directory + RUN mkdir ${KETTLE_HOME} + RUN chmod 775 ${KETTLE_HOME} + # Copy Pentaho PDI from layer install_unpack to this layer COPY --from=install_unpack --chmod=775 ${PENTAHO_INSTALL}/data-integration/ ${KETTLE_HOME}/ From 45bf2333c7eef1ffc12242f460c94a69befc4f79 Mon Sep 17 00:00:00 2001 From: "silke.schmid" Date: Wed, 29 May 2024 10:42:49 +0200 Subject: [PATCH 11/16] using WORKDIR --- .github/workflows/release-image.yaml | 9 ++++----- Dockerfile | 15 ++++++--------- 2 files changed, 10 insertions(+), 14 deletions(-) diff --git a/.github/workflows/release-image.yaml b/.github/workflows/release-image.yaml index 46789c1..f9bd029 100644 --- a/.github/workflows/release-image.yaml +++ b/.github/workflows/release-image.yaml @@ -3,13 +3,13 @@ name: Create and publish Docker image on: workflow_dispatch: inputs: - branch: - description: "Branch to release from ?" - required: true - default: "main" release-tag: description: "Release tag ?" required: true + do_release: + description: "Create Github Release ? (true/false)" + required: true + default: "false" env: REGISTRY: ghcr.io @@ -31,7 +31,6 @@ jobs: - name: Log in to the Container registry uses: docker/login-action@v3 with: - ref: ${{ inputs.branch }} registry: ${{ env.REGISTRY }} username: ${{ github.actor }} password: ${{ secrets.GITHUB_TOKEN }} diff --git a/Dockerfile b/Dockerfile index 23c00d5..c31678e 100644 --- a/Dockerfile +++ b/Dockerfile @@ -14,11 +14,12 @@ # Pentaho Directory RUN mkdir ${PENTAHO_INSTALL} - RUN chmod 775 ${PENTAHO_INSTALL} + + WORKDIR ${PENTAHO_INSTALL} # Download PDI and extract it RUN curl ${PENTAHO_URL} -o $HOME/pdi-ce-${PDI_VERSION}.zip - RUN cd $PENTAHO_INSTALL && jar -xvf $HOME/pdi-ce-${PDI_VERSION}.zip + RUN jar -xvf $HOME/pdi-ce-${PDI_VERSION}.zip ################################################################################################## # Second layer: Here is where we create the final image # @@ -36,19 +37,16 @@ # Environment settings ENV PENTAHO_JAVA_HOME=$JAVA_HOME - ENV PENTAHO_HOME=$HOME/pentaho ENV CARTE_PORT=8080 - ENV KETTLE_HOME=${PENTAHO_HOME}/data-integration + ENV KETTLE_HOME=${HOME}/data-integration ENV PATH=${KETTLE_HOME}:$PATH - # Create PENTAHO_HOME directory - RUN mkdir ${PENTAHO_HOME} - RUN chmod 775 ${PENTAHO_HOME} - # Create PENTAHO_HOME directory RUN mkdir ${KETTLE_HOME} RUN chmod 775 ${KETTLE_HOME} + WORKDIR ${KETTLE_HOME} + # Copy Pentaho PDI from layer install_unpack to this layer COPY --from=install_unpack --chmod=775 ${PENTAHO_INSTALL}/data-integration/ ${KETTLE_HOME}/ @@ -56,5 +54,4 @@ RUN chmod 755 ${KETTLE_HOME}/*.sh # Start Carte Server - RUN cd ${KETTLE_HOME} CMD ${KETTLE_HOME}/carte.sh ${HOSTNAME} ${CARTE_PORT} \ No newline at end of file From 886981ff8cab26fad76e82e00621ff0401b13e4e Mon Sep 17 00:00:00 2001 From: "silke.schmid" Date: Wed, 29 May 2024 11:54:15 +0200 Subject: [PATCH 12/16] Change CMD command syntax --- Dockerfile | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/Dockerfile b/Dockerfile index c31678e..6a134e4 100644 --- a/Dockerfile +++ b/Dockerfile @@ -41,7 +41,7 @@ ENV KETTLE_HOME=${HOME}/data-integration ENV PATH=${KETTLE_HOME}:$PATH - # Create PENTAHO_HOME directory + # Create KETTLE_HOME directory and make it writeable RUN mkdir ${KETTLE_HOME} RUN chmod 775 ${KETTLE_HOME} @@ -54,4 +54,4 @@ RUN chmod 755 ${KETTLE_HOME}/*.sh # Start Carte Server - CMD ${KETTLE_HOME}/carte.sh ${HOSTNAME} ${CARTE_PORT} \ No newline at end of file + CMD ["${KETTLE_HOME}/carte.sh", "${HOSTNAME}", "${CARTE_PORT}"] \ No newline at end of file From 721c26883da84c0813eb046960a121fba128fe03 Mon Sep 17 00:00:00 2001 From: "silke.schmid" Date: Wed, 29 May 2024 12:07:12 +0200 Subject: [PATCH 13/16] Changed CMD syntax --- Dockerfile | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Dockerfile b/Dockerfile index 6a134e4..47fcde2 100644 --- a/Dockerfile +++ b/Dockerfile @@ -54,4 +54,4 @@ RUN chmod 755 ${KETTLE_HOME}/*.sh # Start Carte Server - CMD ["${KETTLE_HOME}/carte.sh", "${HOSTNAME}", "${CARTE_PORT}"] \ No newline at end of file + CMD [${KETTLE_HOME}/carte.sh, ${HOSTNAME}, ${CARTE_PORT}] \ No newline at end of file From f04b3216b55b14de9f2e7e26a37281bbfcd713d3 Mon Sep 17 00:00:00 2001 From: "silke.schmid" Date: Wed, 29 May 2024 12:50:25 +0200 Subject: [PATCH 14/16] Revert changes to CMD syntax --- Dockerfile | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/Dockerfile b/Dockerfile index 47fcde2..746e085 100644 --- a/Dockerfile +++ b/Dockerfile @@ -41,7 +41,7 @@ ENV KETTLE_HOME=${HOME}/data-integration ENV PATH=${KETTLE_HOME}:$PATH - # Create KETTLE_HOME directory and make it writeable + # Create PENTAHO_HOME directory and make it writable RUN mkdir ${KETTLE_HOME} RUN chmod 775 ${KETTLE_HOME} @@ -54,4 +54,4 @@ RUN chmod 755 ${KETTLE_HOME}/*.sh # Start Carte Server - CMD [${KETTLE_HOME}/carte.sh, ${HOSTNAME}, ${CARTE_PORT}] \ No newline at end of file + CMD ${KETTLE_HOME}/carte.sh ${HOSTNAME} ${CARTE_PORT} \ No newline at end of file From 61d06d2a0c0932d0c13b1596ff46dd1c6251d333 Mon Sep 17 00:00:00 2001 From: "silke.schmid" Date: Mon, 24 Jun 2024 14:11:23 +0200 Subject: [PATCH 15/16] Link to available Helm Chart activated --- ReadMe.md | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) diff --git a/ReadMe.md b/ReadMe.md index f592d67..7be4f61 100644 --- a/ReadMe.md +++ b/ReadMe.md @@ -31,9 +31,7 @@ Use Pentaho Carte Server's [default user and password](https://pentaho-public.a ### Deploying on Kubernetes using a Helm chart -We will provide a Helm Chart for *pentaho-carte* soon under [provided Helm chart][helm-chart-github]. - - +If you want to deploy pentaho-carte on a Kubernetes cluster, you can use the [provided Helm chart][helm-chart-github]. ### Configuration From 77a8dab61afec09f576004fbc5b3a15ceb269849 Mon Sep 17 00:00:00 2001 From: Silke <33521006+ejcsid@users.noreply.github.com> Date: Fri, 2 Aug 2024 12:10:58 +0200 Subject: [PATCH 16/16] mkdir & chmod in one line Co-authored-by: Hans <11695964+hupling@users.noreply.github.com> --- Dockerfile | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/Dockerfile b/Dockerfile index 746e085..5a84ae9 100644 --- a/Dockerfile +++ b/Dockerfile @@ -42,8 +42,7 @@ ENV PATH=${KETTLE_HOME}:$PATH # Create PENTAHO_HOME directory and make it writable - RUN mkdir ${KETTLE_HOME} - RUN chmod 775 ${KETTLE_HOME} + RUN mkdir ${KETTLE_HOME} && chmod 775 ${KETTLE_HOME} WORKDIR ${KETTLE_HOME}