diff --git a/charts/incubator/ghostfolio/.helmignore b/charts/incubator/ghostfolio/.helmignore new file mode 100644 index 00000000000..77ca5567b26 --- /dev/null +++ b/charts/incubator/ghostfolio/.helmignore @@ -0,0 +1,30 @@ +# Patterns to ignore when building packages. +# This supports shell glob matching, relative path matching, and +# negation (prefixed with !). Only one pattern per line. +.DS_Store +# Common VCS dirs +.git/ +.gitignore +.bzr/ +.bzrignore +.hg/ +.hgignore +.svn/ +# Common backup files +*.swp +*.bak +*.tmp +*~ +# Various IDEs +.project +.idea/ +*.tmproj +.vscode/ +# OWNERS file for Kubernetes +OWNERS +# helm-docs templates +*.gotmpl +# docs folder +/docs +# icon +icon.png diff --git a/charts/incubator/ghostfolio/CHANGELOG.md b/charts/incubator/ghostfolio/CHANGELOG.md new file mode 100644 index 00000000000..825c32f0d03 --- /dev/null +++ b/charts/incubator/ghostfolio/CHANGELOG.md @@ -0,0 +1 @@ +# Changelog diff --git a/charts/incubator/ghostfolio/Chart.yaml b/charts/incubator/ghostfolio/Chart.yaml new file mode 100644 index 00000000000..b80dafe92df --- /dev/null +++ b/charts/incubator/ghostfolio/Chart.yaml @@ -0,0 +1,32 @@ +apiVersion: v2 +appVersion: "1.277.0" +dependencies: + - name: common + repository: https://library-charts.truecharts.org + version: 12.14.6 + - name: redis + repository: https://deps.truecharts.org + version: 6.0.58 +deprecated: false +description: Ghostfolio is a privacy-first, open source dashboard for your personal finances. Break down your asset allocation, know your net worth and make solid, data-driven investment decisions. +home: https://truecharts.org/charts/incubator/ghostfolio +icon: https://truecharts.org/img/hotlink-ok/chart-icons/ghostfolio.png +keywords: + - ghostfolio + - finance +kubeVersion: ">=1.16.0-0" +maintainers: + - email: info@truecharts.org + name: TrueCharts + url: https://truecharts.org +name: ghostfolio +sources: + - https://github.com/truecharts/charts/tree/master/charts/incubator/ghostfolio + - https://github.com/ghostfolio/ghostfolio + - https://ghostfol.io/ +type: application +version: 0.0.1 +annotations: + truecharts.org/catagories: | + - finance + truecharts.org/SCALE-support: "true" diff --git a/charts/incubator/ghostfolio/README.md b/charts/incubator/ghostfolio/README.md new file mode 100644 index 00000000000..7e59600739c --- /dev/null +++ b/charts/incubator/ghostfolio/README.md @@ -0,0 +1 @@ +# README diff --git a/charts/incubator/ghostfolio/icon.png b/charts/incubator/ghostfolio/icon.png new file mode 100644 index 00000000000..3f3ce881e29 Binary files /dev/null and b/charts/incubator/ghostfolio/icon.png differ diff --git a/charts/incubator/ghostfolio/questions.yaml b/charts/incubator/ghostfolio/questions.yaml new file mode 100644 index 00000000000..06eb1b02546 --- /dev/null +++ b/charts/incubator/ghostfolio/questions.yaml @@ -0,0 +1,97 @@ + +# Include{groups} +portals: + open: +# Include{portalLink} +questions: +# Include{global} +# Include{workload} +# Include{workloadDeployment} + +# Include{replicas1} +# Include{podSpec} +# Include{containerMain} + - variable: env + label: Image Environment + schema: + additional_attrs: true + type: dict + attrs: + - variable: ALPHA_VANTAGE_API_KEY + label: "Alpha Vantage API Key" + description: "https://www.alphavantage.co/ API key" + schema: + type: string + private: true + default: "" + +# Include{containerBasic} +# Include{containerAdvanced} +# Include{containerConfig} +# Include{serviceRoot} +# Include{serviceMain} +# Include{serviceSelectorLoadBalancer} +# Include{serviceSelectorExtras} + - variable: main + label: Main Service Port Configuration + schema: + additional_attrs: true + type: dict + attrs: + - variable: port + label: Port + description: This port exposes the container port on the service + schema: + type: int + default: 3333 + required: true +# Include{serviceExpertRoot} +# Include{serviceExpert} +# Include{serviceList} +# Include{persistenceRoot} +# Include{persistenceBasic} +# Include{persistenceBasic} +# Include{persistenceList} +# Include{ingressRoot} + - variable: main + label: Main Ingress + schema: + additional_attrs: true + type: dict + attrs: +# Include{ingressDefault} +# Include{ingressTLS} +# Include{ingressTraefik} +# Include{ingressAdvanced} +# Include{ingressList} +# Include{securityContextRoot} + + - variable: runAsUser + label: runAsUser + description: The UserID of the user running the application + schema: + type: int + default: 0 + - variable: runAsGroup + label: runAsGroup + description: The groupID this App of the user running the application + schema: + type: int + default: 0 +# Include{securityContextContainer} +# Include{securityContextAdvanced} +# Include{securityContextPod} + - variable: fsGroup + label: fsGroup + description: The group that should own ALL storage. + schema: + type: int + default: 568 + +# Include{resources} +# Include{advanced} +# Include{addons} +# Include{codeserver} +# Include{netshoot} +# Include{vpn} +# Include{documentation} diff --git a/charts/incubator/ghostfolio/templates/NOTES.txt b/charts/incubator/ghostfolio/templates/NOTES.txt new file mode 100644 index 00000000000..efcb74cb772 --- /dev/null +++ b/charts/incubator/ghostfolio/templates/NOTES.txt @@ -0,0 +1 @@ +{{- include "tc.v1.common.lib.chart.notes" $ -}} diff --git a/charts/incubator/ghostfolio/templates/_secrets.tpl b/charts/incubator/ghostfolio/templates/_secrets.tpl new file mode 100644 index 00000000000..573318baa45 --- /dev/null +++ b/charts/incubator/ghostfolio/templates/_secrets.tpl @@ -0,0 +1,20 @@ +{{/* Define the secrets */}} +{{- define "ghostfolio.secrets" -}} +{{- $secretName := (printf "%s-ghostfolio-secrets" (include "tc.v1.common.lib.chart.names.fullname" $)) -}} + +{{/* Initialize all keys */}} +{{- $accesstokensalt := randAlphaNum 50 }} +{{- $jwtsecret := randAlphaNum 50 }} + + {{- with (lookup "v1" "Secret" .Release.Namespace $secretName) -}} + {{/* Get previous values and decode */}} + {{- $accesstokensalt = (index .data "ACCESS_TOKEN_SALT") | b64dec -}} + {{- $jwtsecret = (index .data "JWT_SECRET_KEY") | b64dec -}} + {{- end }} + +enabled: true +data: + ACCESS_TOKEN_SALT: {{ $accesstokensalt }} + JWT_SECRET_KEY: {{ $jwtsecret }} + DATABASE_URL: {{ (printf "%s?client_encoding=utf8" (.Values.cnpg.main.creds.std | trimAll "\"")) | quote }} +{{- end -}} diff --git a/charts/incubator/ghostfolio/templates/common.yaml b/charts/incubator/ghostfolio/templates/common.yaml new file mode 100644 index 00000000000..dd221222457 --- /dev/null +++ b/charts/incubator/ghostfolio/templates/common.yaml @@ -0,0 +1,11 @@ +{{/* Make sure all variables are set properly */}} +{{- include "tc.v1.common.loader.init" . }} + +{{/* Render secrets for ghostfolio */}} +{{- $secrets := include "ghostfolio.secrets" . | fromYaml -}} +{{- if $secrets -}} + {{- $_ := set .Values.secret "secrets" $secrets -}} +{{- end -}} + +{{/* Render the templates */}} +{{ include "tc.v1.common.loader.apply" . }} diff --git a/charts/incubator/ghostfolio/values.yaml b/charts/incubator/ghostfolio/values.yaml new file mode 100644 index 00000000000..d041a4d1cd0 --- /dev/null +++ b/charts/incubator/ghostfolio/values.yaml @@ -0,0 +1,73 @@ +image: + repository: tccr.io/truecharts/ghostfolio + pullPolicy: IfNotPresent + tag: v1.283.5 + +workload: + main: + podSpec: + containers: + main: + probes: + liveness: + path: "/" + type: http + readiness: + path: "/" + type: http + startup: + path: "/" + type: http + env: + ALPHA_VANTAGE_API_KEY: "" + ACCESS_TOKEN_SALT: + secretKeyRef: + name: secrets + key: ACCESS_TOKEN_SALT + JWT_SECRET_KEY: + secretKeyRef: + name: secrets + key: JWT_SECRET_KEY + DATABASE_URL: + secretKeyRef: + name: secrets + key: DATABASE_URL + REDIS_HOST: + secretKeyRef: + expandObjectName: false + name: '{{ printf "%s-%s" .Release.Name "rediscreds" }}' + key: plainhost + REDIS_PASSWORD: + secretKeyRef: + expandObjectName: false + name: '{{ printf "%s-%s" .Release.Name "rediscreds" }}' + key: redis-password + REDIS_PORT: "6379" + +service: + main: + ports: + main: + port: 3333 + targetPort: 3333 + +cnpg: + main: + enabled: true + user: ghostfolio + database: ghostfolio + +redis: + enabled: true + +securityContext: + container: + runAsNonRoot: false + readOnlyRootFilesystem: false + runAsUser: 0 + runAsGroup: 0 + fsGroup: 568 + +portal: + open: + enabled: true