From 0c4c5598205a741bbb831f1f2943d8cb9642e8d2 Mon Sep 17 00:00:00 2001 From: Stavros Kois <47820033+stavros-k@users.noreply.github.com> Date: Thu, 17 Mar 2022 00:56:59 +0200 Subject: [PATCH] feat(jdownloader2): make gui easier - Breaking Change (#2154) * feat(jdownloader2): make gui easier * fix values and add persistence * whoops * pass --- charts/stable/jdownloader2/Chart.yaml | 2 +- charts/stable/jdownloader2/questions.yaml | 62 ++++++++++++++++++----- charts/stable/jdownloader2/values.yaml | 24 +++++++-- 3 files changed, 70 insertions(+), 18 deletions(-) diff --git a/charts/stable/jdownloader2/Chart.yaml b/charts/stable/jdownloader2/Chart.yaml index 809bb7e36df..2c4324a104b 100644 --- a/charts/stable/jdownloader2/Chart.yaml +++ b/charts/stable/jdownloader2/Chart.yaml @@ -23,7 +23,7 @@ sources: - https://hub.docker.com/r/jlesage/jdownloader-2 - https://jdownloader.org/ type: application -version: 6.0.2 +version: 7.0.0 annotations: truecharts.org/catagories: | - downloads diff --git a/charts/stable/jdownloader2/questions.yaml b/charts/stable/jdownloader2/questions.yaml index c97b8af4d64..f021a3eea34 100644 --- a/charts/stable/jdownloader2/questions.yaml +++ b/charts/stable/jdownloader2/questions.yaml @@ -89,25 +89,19 @@ questions: type: string private: true default: "REPLACETHIS" - - variable: env + - variable: jdownloader group: "Container Configuration" - label: "Image Environment" + label: "jDownloader2 Configuration" schema: additional_attrs: true type: dict attrs: - - variable: PUID - label: "PUID" - description: "Sets the PUID env var for jdownloader2 containers" - schema: - type: int - default: 568 - variable: KEEP_APP_RUNNING label: "KEEP_APP_RUNNING" description: "When set to 1, the application will be automatically restarted if it crashes or if a user quits it." schema: - type: int - default: 0 + type: boolean + default: false - variable: gui label: "GUI Settings" description: "Always read description before changing a value here. Also refer to README" @@ -134,9 +128,8 @@ questions: label: "SECURE_CONNECTION" description: "When set to 1, an encrypted connection is used to access the application's GUI (either via a web browser or VNC client). See the Security section for more details." schema: - type: int - default: 0 - required: true + type: boolean + default: false # Include{containerConfig} - variable: service @@ -384,6 +377,49 @@ questions: description: "Default" - value: "Memory" description: "Memory" +# Include{persistenceAdvanced} + - variable: output + label: "App Output Storage" + description: "Stores the Application Output." + schema: + additional_attrs: true + type: dict + attrs: + - variable: type + label: "Type of Storage" + description: "Sets the persistence type, Anything other than PVC could break rollback!" + schema: + type: string + default: "simplePVC" + enum: + - value: "simplePVC" + description: "PVC (simple)" + - value: "simpleHP" + description: "HostPath (simple)" + - value: "emptyDir" + description: "emptyDir" + - value: "pvc" + description: "pvc" + - value: "hostPath" + description: "hostPath" +# Include{persistenceBasic} + - variable: hostPath + label: "hostPath" + description: "Path inside the container the storage is mounted" + schema: + show_if: [["type", "=", "hostPath"]] + type: hostpath + - variable: medium + label: "EmptyDir Medium" + schema: + show_if: [["type", "=", "emptyDir"]] + type: string + default: "" + enum: + - value: "" + description: "Default" + - value: "Memory" + description: "Memory" # Include{persistenceAdvanced} # Include{persistenceList} - variable: ingress diff --git a/charts/stable/jdownloader2/values.yaml b/charts/stable/jdownloader2/values.yaml index 7a442e57f5f..44682c8bade 100644 --- a/charts/stable/jdownloader2/values.yaml +++ b/charts/stable/jdownloader2/values.yaml @@ -32,18 +32,34 @@ service: port: 10056 targetPort: 5900 +envFrom: + - configMapRef: + name: '{{ include "common.names.fullname" . }}-jdownloader' + secret: VNC_PASSWORD: "" -env: + +jdownloader: # General Settings - KEEP_APP_RUNNING: 0 - CLEAN_TMP_DIR: 1 + KEEP_APP_RUNNING: false # GUI Settings DISPLAY_WIDTH: 1280 DISPLAY_HEIGHT: 768 - SECURE_CONNECTION: 0 + SECURE_CONNECTION: false + +configmap: + jdownloader: + enabled: true + data: + KEEP_APP_RUNNING: "{{ ternary \"1\" \"0\" .Values.jdownloader.KEEP_APP_RUNNING }}" + SECURE_CONNECTION: "{{ ternary \"1\" \"0\" .Values.jdownloader.SECURE_CONNECTION }}" + DISPLAY_WIDTH: "{{ .Values.jdownloader.DISPLAY_WIDTH }}" + DISPLAY_HEIGHT: "{{ .Values.jdownloader.DISPLAY_HEIGHT }}" persistence: config: enabled: true mountPath: "/config" + output: + enabled: true + mountPath: "/output"