From 6c8ac774e81b25456a1dae830080111c48b5622d Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Skyler=20M=C3=A4ntysaari?= Date: Wed, 15 Feb 2023 04:40:41 +0200 Subject: [PATCH] Commands do work for the most part The frontend needs better way than sed to change the api endpoint. --- .../piped/templates/backend/lib/_names.tpl | 2 +- .../piped/templates/frontend/lib/_names.tpl | 2 +- .../piped/templates/ytproxy/lib/_names.tpl | 2 +- charts/apps/piped/values.yaml | 30 +++++++++++++++---- 4 files changed, 28 insertions(+), 8 deletions(-) diff --git a/charts/apps/piped/templates/backend/lib/_names.tpl b/charts/apps/piped/templates/backend/lib/_names.tpl index ca15827..64692f8 100644 --- a/charts/apps/piped/templates/backend/lib/_names.tpl +++ b/charts/apps/piped/templates/backend/lib/_names.tpl @@ -24,7 +24,7 @@ If release name contains chart name it will be used as a full name. {{- if contains $name .Release.Name -}} {{- $name = .Release.Name -}} {{- else -}} - {{- $name = printf "%s-%s" .Release.Name $name -}} + {{- $name = printf "%s" $name -}} {{- end -}} {{- end -}} {{- trunc 50 $name | trimSuffix "-" -}} diff --git a/charts/apps/piped/templates/frontend/lib/_names.tpl b/charts/apps/piped/templates/frontend/lib/_names.tpl index 8439ca5..d27d860 100644 --- a/charts/apps/piped/templates/frontend/lib/_names.tpl +++ b/charts/apps/piped/templates/frontend/lib/_names.tpl @@ -24,7 +24,7 @@ If release name contains chart name it will be used as a full name. {{- if contains $name .Release.Name -}} {{- $name = .Release.Name -}} {{- else -}} - {{- $name = printf "%s-%s" .Release.Name $name -}} + {{- $name = printf "%s" $name -}} {{- end -}} {{- end -}} {{- trunc 50 $name | trimSuffix "-" -}} diff --git a/charts/apps/piped/templates/ytproxy/lib/_names.tpl b/charts/apps/piped/templates/ytproxy/lib/_names.tpl index fb54283..289a11d 100644 --- a/charts/apps/piped/templates/ytproxy/lib/_names.tpl +++ b/charts/apps/piped/templates/ytproxy/lib/_names.tpl @@ -24,7 +24,7 @@ If release name contains chart name it will be used as a full name. {{- if contains $name .Release.Name -}} {{- $name = .Release.Name -}} {{- else -}} - {{- $name = printf "%s-%s" .Release.Name $name -}} + {{- $name = printf "%s" $name -}} {{- end -}} {{- end -}} {{- trunc 50 $name | trimSuffix "-" -}} diff --git a/charts/apps/piped/values.yaml b/charts/apps/piped/values.yaml index f8c9952..d06e882 100644 --- a/charts/apps/piped/values.yaml +++ b/charts/apps/piped/values.yaml @@ -11,7 +11,7 @@ global: controller: # -- enable the controller. - enabled: true + enabled: false serviceAccount: create: false @@ -33,16 +33,18 @@ frontend: image: # -- image repository - repository: 1337kavin/piped + repository: 1337kavin/piped-frontend # -- image tag # @chart.appVersion tag: # -- image pull policy pullPolicy: IfNotPresent - command: "/bin/ash -c" - args: - - sed -i s/pipedapi.kavin.rocks/BACKEND_HOSTNAME/g /usr/share/nginx/html/assets/* && /docker-entrypoint.sh && nginx -g "daemon off;" + # Using currently container default + #command: "/bin/tail" + #args: + # - -c +# - "sed -i s/pipedapi.kavin.rocks/BACKEND_HOSTNAME/g /usr/share/nginx/html/assets/*" backend: enabled: true @@ -58,6 +60,22 @@ backend: port: 8080 protocol: HTTP + command: "/opt/java/openjdk/bin/java" + args: + - -server + - -Xmx1G + - -Xaggressive + - -XX:+UnlockExperimentalVMOptions + - -XX:+OptimizeStringConcat + - -XX:+UseStringDeduplication + - -XX:+UseCompressedOops + - -XX:+UseNUMA + - -Xgcpolicy:gencon + - -Xshareclasses:allowClasspaths + - -Xtune:virtualized + - -jar + - /app/piped.jar + image: # -- image repository repository: 1337kavin/piped @@ -83,6 +101,8 @@ ytproxy: port: 8080 protocol: HTTP + command: "/app/piped-proxy" + image: # -- image repository