diff --git a/charts/incubator/kavitaemail/questions.yaml b/charts/incubator/kavitaemail/questions.yaml index f21546ea9fe..696a70425cb 100644 --- a/charts/incubator/kavitaemail/questions.yaml +++ b/charts/incubator/kavitaemail/questions.yaml @@ -171,4 +171,8 @@ questions: # Include{resources} # Include{advanced} # Include{addons} +# Include{codeserver} +# Include{promtail} +# Include{netshoot} +# Include{vpn} # Include{documentation} diff --git a/charts/incubator/midarr/.helmignore b/charts/incubator/midarr/.helmignore new file mode 100644 index 00000000000..77ca5567b26 --- /dev/null +++ b/charts/incubator/midarr/.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/midarr/Chart.yaml b/charts/incubator/midarr/Chart.yaml new file mode 100644 index 00000000000..224e9f55221 --- /dev/null +++ b/charts/incubator/midarr/Chart.yaml @@ -0,0 +1,30 @@ +apiVersion: v2 +appVersion: "10.6.2" +dependencies: + - name: common + repository: https://library-charts.truecharts.org + version: 10.6.4 + - condition: postgresql.enabled + name: postgresql + repository: https://charts.truecharts.org/ + version: 8.0.88 +description: Midarr is a minimal lightweight media server for enjoying your media +home: https://truecharts.org/docs/charts/stable/airsonic +icon: https://truecharts.org/img/hotlink-ok/chart-icons/airsonic.png +keywords: + - midarr +kubeVersion: ">=1.16.0-0" +maintainers: + - email: info@truecharts.org + name: TrueCharts + url: https://truecharts.org +name: midarr +sources: + - https://github.com/truecharts/charts/tree/master/charts/stable/airsonic + - https://github.com/midarrlabs/midarr-server +version: 0.0.1 +annotations: + truecharts.org/catagories: | + - media + truecharts.org/SCALE-support: "true" + truecharts.org/grade: U diff --git a/charts/incubator/midarr/README.md b/charts/incubator/midarr/README.md new file mode 100644 index 00000000000..e69de29bb2d diff --git a/charts/incubator/midarr/icon.png b/charts/incubator/midarr/icon.png new file mode 100644 index 00000000000..30c67e17952 Binary files /dev/null and b/charts/incubator/midarr/icon.png differ diff --git a/charts/incubator/midarr/questions.yaml b/charts/incubator/midarr/questions.yaml new file mode 100644 index 00000000000..62b0e1e5924 --- /dev/null +++ b/charts/incubator/midarr/questions.yaml @@ -0,0 +1,200 @@ +# Include{groups} +portals: + open: +# Include{portalLink} +questions: +# Include{global} +# Include{controller} +# Include{controllerDeployment} +# Include{replicas} +# Include{replica1} +# Include{strategy} +# Include{recreate} +# Include{controllerExpert} +# Include{controllerExpertExtraArgs} + - variable: midarr + group: Container Configuration + label: Midarr Configuration + schema: + additional_attrs: true + type: dict + attrs: + - variable: admin + label: Admin Configuration + schema: + additional_attrs: true + type: dict + attrs: + - variable: mail + label: Admin Mail + schema: + type: string + default: "" + - variable: name + label: Admin Name + schema: + type: string + default: "" + - variable: pass + label: Admin Password + schema: + type: string + private: true + default: "" + - variable: general + label: General Configuration + schema: + additional_attrs: true + type: dict + attrs: + - variable: app_url + label: App URL + description: App URL in format http(s)://IPorFQDN:(port) + schema: + type: string + required: true + default: "" + - variable: app_mailer_from + label: Mailer From + schema: + type: string + default: "" + - variable: sendgrid_api_key + label: SendGrid API Key + schema: + type: string + private: true + default: "" + - variable: radarr + label: Radarr Configuration + schema: + additional_attrs: true + type: dict + attrs: + - variable: base_url + label: Base URL + schema: + type: string + default: "" + - variable: api_key + label: API Key + schema: + type: string + private: true + default: "" + - variable: sonarr + label: Sonarr Configuration + schema: + additional_attrs: true + type: dict + attrs: + - variable: base_url + label: Base URL + schema: + type: string + default: "" + - variable: api_key + label: API Key + schema: + type: string + private: true + default: "" +# Include{containerConfig} +# Include{serviceRoot} + - variable: main + label: Main Service + description: The Primary service on which the healthcheck runs, often the webUI + schema: + additional_attrs: true + type: dict + attrs: +# 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: 10347 + required: true +# Include{advancedPortHTTP} + - variable: targetPort + label: Target Port + description: The internal(!) port on the container the Application runs on + schema: + type: int + default: 4000 +# Include{serviceExpertRoot} + default: false +# Include{serviceExpert} +# Include{serviceList} +# Include{persistenceList} +# Include{ingressRoot} + - variable: main + label: Main Ingress + schema: + additional_attrs: true + type: dict + attrs: +# Include{ingressDefault} +# Include{ingressTLS} +# Include{ingressTraefik} +# Include{ingressExpert} +# Include{ingressList} +# Include{security} +# Include{securityContextAdvancedRoot} + - variable: privileged + label: Privileged mode + schema: + type: boolean + default: false + - variable: readOnlyRootFilesystem + label: ReadOnly Root Filesystem + schema: + type: boolean + default: false + - variable: allowPrivilegeEscalation + label: Allow Privilege Escalation + schema: + type: boolean + default: false + - variable: runAsNonRoot + label: runAsNonRoot + schema: + type: boolean + default: false +# Include{securityContextAdvanced} +# Include{podSecurityContextRoot} + - 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 + - variable: fsGroup + label: fsGroup + description: The group that should own ALL storage. + schema: + type: int + default: 568 +# Include{podSecurityContextAdvanced} +# Include{resources} +# Include{advanced} +# Include{addons} +# Include{codeserver} +# Include{promtail} +# Include{netshoot} +# Include{vpn} +# Include{documentation} diff --git a/charts/incubator/midarr/templates/_config.tpl b/charts/incubator/midarr/templates/_config.tpl new file mode 100644 index 00000000000..dcf4f8fca12 --- /dev/null +++ b/charts/incubator/midarr/templates/_config.tpl @@ -0,0 +1,36 @@ +{{/* Define the configmap */}} +{{- define "midarr.config" -}} + +{{- $configName := printf "%s-config" (include "tc.common.names.fullname" .) }} + +--- + +apiVersion: v1 +kind: ConfigMap +metadata: + name: {{ $configName }} + labels: + {{- include "tc.common.labels" . | nindent 4 }} +data: + DB_USERNAME: {{ .Values.postgresql.postgresqlUsername }} + DB_DATABASE: {{ .Values.postgresql.postgresqlDatabase }} + DB_HOSTNAME: {{ printf "%v-%v" .Release.Name "postgresql" }} + {{- with .Values.midarr.admin.mail }} + SETUP_ADMIN_EMAIL: {{ . }} + {{- end }} + {{- with .Values.midarr.admin.name }} + SETUP_ADMIN_NAME: {{ . }} + {{- end }} + {{- with .Values.midarr.radarr.base_url }} + RADARR_BASE_URL: {{ . }} + {{- end }} + {{- with .Values.midarr.sonarr.base_url }} + SONARR_BASE_URL: {{ . }} + {{- end }} + {{- with .Values.midarr.general.app_url }} + APP_URL: http://localhost:4000 + {{- end }} + {{- with .Values.midarr.general.app_mailer_from }} + APP_MAILER_FROM: example@email.com + {{- end }} +{{- end -}} diff --git a/charts/incubator/midarr/templates/_secret.tpl b/charts/incubator/midarr/templates/_secret.tpl new file mode 100644 index 00000000000..6c73186a285 --- /dev/null +++ b/charts/incubator/midarr/templates/_secret.tpl @@ -0,0 +1,29 @@ +{{/* Define the secret */}} +{{- define "midarr.secret" -}} + +{{- $secretName := printf "%s-secret" (include "tc.common.names.fullname" .) }} + +--- + +apiVersion: v1 +kind: Secret +type: Opaque +metadata: + name: {{ $secretName }} + labels: + {{- include "tc.common.labels" . | nindent 4 }} +data: + DB_PASSWORD: {{ .Values.postgresql.postgresqlPassword | trimAll "\"" | b64enc }} + {{- with .Values.midarr.admin.pass }} + SETUP_ADMIN_PASSWORD: {{ . | b64enc }} + {{- end }} + {{- with .Values.midarr.radarr.api_key }} + RADARR_API_KEY: {{ . | b64enc }} + {{- end }} + {{- with .Values.midarr.sonarr.api_key }} + SONARR_API_KEY: {{ . | b64enc }} + {{- end }} + {{- with .Values.midarr.general.sendgrid_api_key }} + SENDGRID_API_KEY: {{ . | b64enc }} + {{- end }} +{{- end }} diff --git a/charts/incubator/midarr/templates/common.yaml b/charts/incubator/midarr/templates/common.yaml new file mode 100644 index 00000000000..16d86426332 --- /dev/null +++ b/charts/incubator/midarr/templates/common.yaml @@ -0,0 +1,11 @@ +{{/* Make sure all variables are set properly */}} +{{- include "tc.common.loader.init" . }} + +{{/* Render config */}} +{{- include "midarr.config" . }} + +{{/* Render secret */}} +{{- include "midarr.secret" . }} + +{{/* Render the templates */}} +{{ include "tc.common.loader.apply" . }} diff --git a/charts/incubator/midarr/values.yaml b/charts/incubator/midarr/values.yaml new file mode 100644 index 00000000000..a37c2098723 --- /dev/null +++ b/charts/incubator/midarr/values.yaml @@ -0,0 +1,51 @@ +image: + repository: tccr.io/truecharts/midarr-server + tag: v1.16.0@sha256:b2c433337beb328dafe3e6058c1a61ff5872f0ff2f2de1a883d521063ea6c943 + pullPolicy: IfNotPresent + +securityContext: + readOnlyRootFilesystem: false + runAsNonRoot: false + +podSecurityContext: + runAsUser: 0 + runAsGroup: 0 + +midarr: + admin: + mail: admin@example.com + name: admin + pass: password + general: + app_url: http://localhost:4000 + app_mailer_from: midarr@example.com + sendgrid_api_key: "" + radarr: + base_url: "" + api_key: "" + sonarr: + base_url: "" + api_key: "" + +envFrom: + - secretRef: + name: '{{ include "tc.common.names.fullname" . }}-secret' + - configMapRef: + name: '{{ include "tc.common.names.fullname" . }}-config' + +service: + main: + ports: + main: + port: 10347 + protocol: HTTP + targetPort: 4000 + +postgresql: + enabled: true + existingSecret: dbcreds + postgresqlUsername: midarr + postgresqlDatabase: midarr + +portal: + enabled: true diff --git a/cspell.config.yaml b/cspell.config.yaml index 038bdda590a..98cb72837a2 100644 --- a/cspell.config.yaml +++ b/cspell.config.yaml @@ -140,6 +140,7 @@ words: - mergerfs - meshroom - metallb + - Midarr - middlewares - middlewaretcps - mikrotik @@ -213,6 +214,7 @@ words: - schouten - Scipy - selfsigned + - sendgrid - serverconfig - servername - serverstransports