mirror of
https://github.com/rtomik/helm-charts.git
synced 2026-07-16 08:14:48 +00:00
release of norish
This commit is contained in:
74
charts/norish/templates/NOTES.txt
Normal file
74
charts/norish/templates/NOTES.txt
Normal file
@ -0,0 +1,74 @@
|
||||
Thank you for installing {{ .Chart.Name }}!
|
||||
|
||||
Your release is named {{ .Release.Name }}.
|
||||
|
||||
To learn more about the release, try:
|
||||
|
||||
$ helm status {{ .Release.Name }} -n {{ .Release.Namespace }}
|
||||
$ helm get all {{ .Release.Name }} -n {{ .Release.Namespace }}
|
||||
|
||||
{{- if .Values.ingress.enabled }}
|
||||
|
||||
Application URL:
|
||||
{{- range .Values.ingress.hosts }}
|
||||
http{{ if $.Values.ingress.tls }}s{{ end }}://{{ .host }}{{ range .paths }}{{ .path }}{{ end }}
|
||||
{{- end }}
|
||||
{{- else }}
|
||||
|
||||
Get the application URL by running these commands:
|
||||
{{- if contains "NodePort" .Values.service.type }}
|
||||
export NODE_PORT=$(kubectl get --namespace {{ .Release.Namespace }} -o jsonpath="{.spec.ports[0].nodePort}" services {{ include "norish.fullname" . }})
|
||||
export NODE_IP=$(kubectl get nodes --namespace {{ .Release.Namespace }} -o jsonpath="{.items[0].status.addresses[0].address}")
|
||||
echo http://$NODE_IP:$NODE_PORT
|
||||
{{- else if contains "LoadBalancer" .Values.service.type }}
|
||||
NOTE: It may take a few minutes for the LoadBalancer IP to be available.
|
||||
You can watch the status by running 'kubectl get --namespace {{ .Release.Namespace }} svc -w {{ include "norish.fullname" . }}'
|
||||
export SERVICE_IP=$(kubectl get svc --namespace {{ .Release.Namespace }} {{ include "norish.fullname" . }} --template "{{"{{ range (index .status.loadBalancer.ingress 0) }}{{.}}{{ end }}"}}")
|
||||
echo http://$SERVICE_IP:{{ .Values.service.port }}
|
||||
{{- else if contains "ClusterIP" .Values.service.type }}
|
||||
export POD_NAME=$(kubectl get pods --namespace {{ .Release.Namespace }} -l "app.kubernetes.io/name={{ include "norish.name" . }},app.kubernetes.io/instance={{ .Release.Name }}" -o jsonpath="{.items[0].metadata.name}")
|
||||
export CONTAINER_PORT=$(kubectl get pod --namespace {{ .Release.Namespace }} $POD_NAME -o jsonpath="{.spec.containers[0].ports[0].containerPort}")
|
||||
echo "Visit http://127.0.0.1:8080 to use your application"
|
||||
kubectl --namespace {{ .Release.Namespace }} port-forward $POD_NAME 8080:$CONTAINER_PORT
|
||||
{{- end }}
|
||||
{{- end }}
|
||||
|
||||
IMPORTANT CONFIGURATION NOTES:
|
||||
|
||||
1. Database Configuration:
|
||||
{{- if .Values.database.host }}
|
||||
Using external PostgreSQL at: {{ .Values.database.host }}:{{ .Values.database.port }}
|
||||
{{- else }}
|
||||
⚠️ WARNING: Database host is not configured!
|
||||
Configure database.host to point to your PostgreSQL server.
|
||||
{{- end }}
|
||||
|
||||
2. Master Key:
|
||||
{{- if .Values.config.masterKey.existingSecret }}
|
||||
Using existing secret: {{ .Values.config.masterKey.existingSecret }}
|
||||
{{- else }}
|
||||
{{- if not .Values.config.masterKey.value }}
|
||||
⚠️ WARNING: Master key is not set! Generate one with: openssl rand -base64 32
|
||||
{{- else }}
|
||||
Master key configured from values.yaml
|
||||
{{- end }}
|
||||
{{- end }}
|
||||
|
||||
3. Authentication:
|
||||
{{- if or .Values.config.auth.oidc.enabled .Values.config.auth.github.enabled .Values.config.auth.google.enabled }}
|
||||
{{- if .Values.config.auth.oidc.enabled }}
|
||||
- OIDC provider: {{ .Values.config.auth.oidc.name }}
|
||||
{{- end }}
|
||||
{{- if .Values.config.auth.github.enabled }}
|
||||
- GitHub OAuth enabled
|
||||
{{- end }}
|
||||
{{- if .Values.config.auth.google.enabled }}
|
||||
- Google OAuth enabled
|
||||
{{- end }}
|
||||
After first login, configure additional providers in Settings → Admin
|
||||
{{- else }}
|
||||
⚠️ WARNING: No authentication provider configured!
|
||||
Configure ONE provider (OIDC, GitHub, or Google) to create your admin account.
|
||||
{{- end }}
|
||||
|
||||
For more information, visit: https://github.com/norishapp/norish
|
||||
57
charts/norish/templates/_helpers.tpl
Normal file
57
charts/norish/templates/_helpers.tpl
Normal file
@ -0,0 +1,57 @@
|
||||
{{/*
|
||||
Expand the name of the chart.
|
||||
*/}}
|
||||
{{- define "norish.name" -}}
|
||||
{{- default .Chart.Name .Values.nameOverride | trunc 63 | trimSuffix "-" }}
|
||||
{{- end }}
|
||||
|
||||
{{/*
|
||||
Create a default fully qualified app name.
|
||||
*/}}
|
||||
{{- define "norish.fullname" -}}
|
||||
{{- if .Values.fullnameOverride }}
|
||||
{{- .Values.fullnameOverride | trunc 63 | trimSuffix "-" }}
|
||||
{{- else }}
|
||||
{{- $name := default .Chart.Name .Values.nameOverride }}
|
||||
{{- printf "%s" $name | trunc 63 | trimSuffix "-" }}
|
||||
{{- end }}
|
||||
{{- end }}
|
||||
|
||||
{{/*
|
||||
Create chart name and version as used by the chart label.
|
||||
*/}}
|
||||
{{- define "norish.chart" -}}
|
||||
{{- printf "%s-%s" .Chart.Name .Chart.Version | replace "+" "_" | trunc 63 | trimSuffix "-" }}
|
||||
{{- end }}
|
||||
|
||||
{{/*
|
||||
Common labels
|
||||
*/}}
|
||||
{{- define "norish.labels" -}}
|
||||
helm.sh/chart: {{ include "norish.chart" . }}
|
||||
{{ include "norish.selectorLabels" . }}
|
||||
{{- if .Chart.AppVersion }}
|
||||
app.kubernetes.io/version: {{ .Chart.AppVersion | quote }}
|
||||
{{- end }}
|
||||
app.kubernetes.io/managed-by: {{ .Release.Service }}
|
||||
{{- end }}
|
||||
|
||||
{{/*
|
||||
Selector labels
|
||||
*/}}
|
||||
{{- define "norish.selectorLabels" -}}
|
||||
app.kubernetes.io/name: {{ include "norish.name" . }}
|
||||
app.kubernetes.io/instance: {{ .Release.Name }}
|
||||
{{- end }}
|
||||
|
||||
{{/*
|
||||
Database connection URL
|
||||
*/}}
|
||||
{{- define "norish.databaseUrl" -}}
|
||||
{{- $username := .Values.database.username }}
|
||||
{{- $password := .Values.database.password }}
|
||||
{{- $host := .Values.database.host }}
|
||||
{{- $port := .Values.database.port }}
|
||||
{{- $database := .Values.database.name }}
|
||||
{{- printf "postgres://%s:%s@%s:%d/%s" $username $password $host (int $port) $database }}
|
||||
{{- end }}
|
||||
279
charts/norish/templates/deployment-app.yaml
Normal file
279
charts/norish/templates/deployment-app.yaml
Normal file
@ -0,0 +1,279 @@
|
||||
apiVersion: apps/v1
|
||||
kind: Deployment
|
||||
metadata:
|
||||
name: {{ include "norish.fullname" . }}
|
||||
labels:
|
||||
{{- include "norish.labels" . | nindent 4 }}
|
||||
app.kubernetes.io/component: app
|
||||
annotations:
|
||||
checksum/secret: {{ include (print $.Template.BasePath "/secret.yaml") . | sha256sum }}
|
||||
spec:
|
||||
replicas: {{ .Values.replicaCount }}
|
||||
revisionHistoryLimit: {{ .Values.revisionHistoryLimit }}
|
||||
selector:
|
||||
matchLabels:
|
||||
{{- include "norish.selectorLabels" . | nindent 6 }}
|
||||
strategy:
|
||||
type: RollingUpdate
|
||||
rollingUpdate:
|
||||
maxUnavailable: 1
|
||||
maxSurge: 1
|
||||
template:
|
||||
metadata:
|
||||
labels:
|
||||
{{- include "norish.selectorLabels" . | nindent 8 }}
|
||||
annotations:
|
||||
checksum/secret: {{ include (print $.Template.BasePath "/secret.yaml") . | sha256sum }}
|
||||
{{- with .Values.podAnnotations }}
|
||||
{{- toYaml . | nindent 8 }}
|
||||
{{- end }}
|
||||
spec:
|
||||
{{- with .Values.imagePullSecrets }}
|
||||
imagePullSecrets:
|
||||
{{- toYaml . | nindent 8 }}
|
||||
{{- end }}
|
||||
securityContext:
|
||||
{{- toYaml .Values.podSecurityContext | nindent 8 }}
|
||||
containers:
|
||||
- name: {{ .Chart.Name }}
|
||||
securityContext:
|
||||
{{- toYaml .Values.containerSecurityContext | nindent 12 }}
|
||||
image: "{{ .Values.image.repository }}:{{ .Values.image.tag | default .Chart.AppVersion }}"
|
||||
imagePullPolicy: {{ .Values.image.pullPolicy }}
|
||||
ports:
|
||||
- name: http
|
||||
containerPort: {{ .Values.service.port }}
|
||||
protocol: TCP
|
||||
{{- if .Values.probes.startup.enabled }}
|
||||
startupProbe:
|
||||
httpGet:
|
||||
path: {{ .Values.probes.startup.path }}
|
||||
port: http
|
||||
initialDelaySeconds: {{ .Values.probes.startup.initialDelaySeconds }}
|
||||
periodSeconds: {{ .Values.probes.startup.periodSeconds }}
|
||||
timeoutSeconds: {{ .Values.probes.startup.timeoutSeconds }}
|
||||
failureThreshold: {{ .Values.probes.startup.failureThreshold }}
|
||||
successThreshold: {{ .Values.probes.startup.successThreshold }}
|
||||
{{- end }}
|
||||
{{- if .Values.probes.liveness.enabled }}
|
||||
livenessProbe:
|
||||
httpGet:
|
||||
path: {{ .Values.probes.liveness.path }}
|
||||
port: http
|
||||
initialDelaySeconds: {{ .Values.probes.liveness.initialDelaySeconds }}
|
||||
periodSeconds: {{ .Values.probes.liveness.periodSeconds }}
|
||||
timeoutSeconds: {{ .Values.probes.liveness.timeoutSeconds }}
|
||||
failureThreshold: {{ .Values.probes.liveness.failureThreshold }}
|
||||
successThreshold: {{ .Values.probes.liveness.successThreshold }}
|
||||
{{- end }}
|
||||
{{- if .Values.probes.readiness.enabled }}
|
||||
readinessProbe:
|
||||
httpGet:
|
||||
path: {{ .Values.probes.readiness.path }}
|
||||
port: http
|
||||
initialDelaySeconds: {{ .Values.probes.readiness.initialDelaySeconds }}
|
||||
periodSeconds: {{ .Values.probes.readiness.periodSeconds }}
|
||||
timeoutSeconds: {{ .Values.probes.readiness.timeoutSeconds }}
|
||||
failureThreshold: {{ .Values.probes.readiness.failureThreshold }}
|
||||
successThreshold: {{ .Values.probes.readiness.successThreshold }}
|
||||
{{- end }}
|
||||
env:
|
||||
- name: AUTH_URL
|
||||
value: {{ .Values.config.authUrl | quote }}
|
||||
{{- if .Values.chrome.enabled }}
|
||||
- name: CHROME_WS_ENDPOINT
|
||||
value: "ws://localhost:{{ .Values.chrome.port }}"
|
||||
{{- end }}
|
||||
{{- if .Values.config.logLevel }}
|
||||
- name: NEXT_PUBLIC_LOG_LEVEL
|
||||
value: {{ .Values.config.logLevel | quote }}
|
||||
{{- end }}
|
||||
{{- if .Values.config.trustedOrigins }}
|
||||
- name: TRUSTED_ORIGINS
|
||||
value: {{ .Values.config.trustedOrigins | quote }}
|
||||
{{- end }}
|
||||
{{- if .Values.config.passwordAuthEnabled }}
|
||||
- name: PASSWORD_AUTH_ENABLED
|
||||
value: {{ .Values.config.passwordAuthEnabled | quote }}
|
||||
{{- end }}
|
||||
{{- if .Values.database.existingSecret }}
|
||||
- name: DB_USERNAME
|
||||
valueFrom:
|
||||
secretKeyRef:
|
||||
name: {{ .Values.database.existingSecret }}
|
||||
key: {{ .Values.database.usernameKey }}
|
||||
- name: DB_PASSWORD
|
||||
valueFrom:
|
||||
secretKeyRef:
|
||||
name: {{ .Values.database.existingSecret }}
|
||||
key: {{ .Values.database.passwordKey }}
|
||||
{{- if .Values.database.databaseKey }}
|
||||
- name: DB_NAME
|
||||
valueFrom:
|
||||
secretKeyRef:
|
||||
name: {{ .Values.database.existingSecret }}
|
||||
key: {{ .Values.database.databaseKey }}
|
||||
{{- else }}
|
||||
- name: DB_NAME
|
||||
value: {{ .Values.database.name | quote }}
|
||||
{{- end }}
|
||||
{{- if .Values.database.hostKey }}
|
||||
- name: DB_HOST
|
||||
valueFrom:
|
||||
secretKeyRef:
|
||||
name: {{ .Values.database.existingSecret }}
|
||||
key: {{ .Values.database.hostKey }}
|
||||
{{- else }}
|
||||
- name: DB_HOST
|
||||
value: {{ .Values.database.host | quote }}
|
||||
{{- end }}
|
||||
- name: DB_PORT
|
||||
value: {{ .Values.database.port | quote }}
|
||||
- name: DATABASE_URL
|
||||
value: "postgres://$(DB_USERNAME):$(DB_PASSWORD)@$(DB_HOST):$(DB_PORT)/$(DB_NAME)"
|
||||
{{- else }}
|
||||
- name: DATABASE_URL
|
||||
value: {{ include "norish.databaseUrl" . | quote }}
|
||||
{{- end }}
|
||||
- name: MASTER_KEY
|
||||
valueFrom:
|
||||
secretKeyRef:
|
||||
{{- if .Values.config.masterKey.existingSecret }}
|
||||
name: {{ .Values.config.masterKey.existingSecret }}
|
||||
key: {{ .Values.config.masterKey.secretKey }}
|
||||
{{- else }}
|
||||
name: {{ include "norish.fullname" . }}-secret
|
||||
key: master-key
|
||||
{{- end }}
|
||||
{{- if .Values.config.auth.oidc.enabled }}
|
||||
- name: OIDC_NAME
|
||||
value: {{ .Values.config.auth.oidc.name | quote }}
|
||||
- name: OIDC_ISSUER
|
||||
value: {{ .Values.config.auth.oidc.issuer | quote }}
|
||||
{{- if .Values.config.auth.oidc.wellKnown }}
|
||||
- name: OIDC_WELLKNOWN
|
||||
value: {{ .Values.config.auth.oidc.wellKnown | quote }}
|
||||
{{- end }}
|
||||
- name: OIDC_CLIENT_ID
|
||||
valueFrom:
|
||||
secretKeyRef:
|
||||
{{- if .Values.config.auth.oidc.existingSecret }}
|
||||
name: {{ .Values.config.auth.oidc.existingSecret }}
|
||||
key: {{ .Values.config.auth.oidc.clientIdKey }}
|
||||
{{- else }}
|
||||
name: {{ include "norish.fullname" . }}-secret
|
||||
key: oidc-client-id
|
||||
{{- end }}
|
||||
- name: OIDC_CLIENT_SECRET
|
||||
valueFrom:
|
||||
secretKeyRef:
|
||||
{{- if .Values.config.auth.oidc.existingSecret }}
|
||||
name: {{ .Values.config.auth.oidc.existingSecret }}
|
||||
key: {{ .Values.config.auth.oidc.clientSecretKey }}
|
||||
{{- else }}
|
||||
name: {{ include "norish.fullname" . }}-secret
|
||||
key: oidc-client-secret
|
||||
{{- end }}
|
||||
{{- end }}
|
||||
{{- if .Values.config.auth.github.enabled }}
|
||||
- name: GITHUB_CLIENT_ID
|
||||
valueFrom:
|
||||
secretKeyRef:
|
||||
{{- if .Values.config.auth.github.existingSecret }}
|
||||
name: {{ .Values.config.auth.github.existingSecret }}
|
||||
key: {{ .Values.config.auth.github.clientIdKey }}
|
||||
{{- else }}
|
||||
name: {{ include "norish.fullname" . }}-secret
|
||||
key: github-client-id
|
||||
{{- end }}
|
||||
- name: GITHUB_CLIENT_SECRET
|
||||
valueFrom:
|
||||
secretKeyRef:
|
||||
{{- if .Values.config.auth.github.existingSecret }}
|
||||
name: {{ .Values.config.auth.github.existingSecret }}
|
||||
key: {{ .Values.config.auth.github.clientSecretKey }}
|
||||
{{- else }}
|
||||
name: {{ include "norish.fullname" . }}-secret
|
||||
key: github-client-secret
|
||||
{{- end }}
|
||||
{{- end }}
|
||||
{{- if .Values.config.auth.google.enabled }}
|
||||
- name: GOOGLE_CLIENT_ID
|
||||
valueFrom:
|
||||
secretKeyRef:
|
||||
{{- if .Values.config.auth.google.existingSecret }}
|
||||
name: {{ .Values.config.auth.google.existingSecret }}
|
||||
key: {{ .Values.config.auth.google.clientIdKey }}
|
||||
{{- else }}
|
||||
name: {{ include "norish.fullname" . }}-secret
|
||||
key: google-client-id
|
||||
{{- end }}
|
||||
- name: GOOGLE_CLIENT_SECRET
|
||||
valueFrom:
|
||||
secretKeyRef:
|
||||
{{- if .Values.config.auth.google.existingSecret }}
|
||||
name: {{ .Values.config.auth.google.existingSecret }}
|
||||
key: {{ .Values.config.auth.google.clientSecretKey }}
|
||||
{{- else }}
|
||||
name: {{ include "norish.fullname" . }}-secret
|
||||
key: google-client-secret
|
||||
{{- end }}
|
||||
{{- end }}
|
||||
volumeMounts:
|
||||
- name: uploads
|
||||
mountPath: /app/uploads
|
||||
{{- with .Values.extraVolumeMounts }}
|
||||
{{- toYaml . | nindent 12 }}
|
||||
{{- end }}
|
||||
resources:
|
||||
{{- toYaml .Values.resources | nindent 12 }}
|
||||
{{- if .Values.chrome.enabled }}
|
||||
- name: chrome-headless
|
||||
image: "{{ .Values.chrome.image.repository }}:{{ .Values.chrome.image.tag }}"
|
||||
imagePullPolicy: {{ .Values.chrome.image.pullPolicy }}
|
||||
securityContext:
|
||||
{{- toYaml .Values.chrome.securityContext | nindent 12 }}
|
||||
ports:
|
||||
- name: chrome
|
||||
containerPort: {{ .Values.chrome.port }}
|
||||
protocol: TCP
|
||||
command:
|
||||
- chromium-browser
|
||||
args:
|
||||
- "--no-sandbox"
|
||||
- "--disable-gpu"
|
||||
- "--disable-dev-shm-usage"
|
||||
- "--remote-debugging-address=0.0.0.0"
|
||||
- "--remote-debugging-port={{ .Values.chrome.port }}"
|
||||
- "--headless"
|
||||
resources:
|
||||
{{- toYaml .Values.chrome.resources | nindent 12 }}
|
||||
{{- end }}
|
||||
volumes:
|
||||
{{- if .Values.persistence.enabled }}
|
||||
- name: uploads
|
||||
persistentVolumeClaim:
|
||||
{{- if .Values.persistence.existingClaim }}
|
||||
claimName: {{ .Values.persistence.existingClaim }}
|
||||
{{- else }}
|
||||
claimName: {{ include "norish.fullname" . }}-uploads
|
||||
{{- end }}
|
||||
{{- else }}
|
||||
- name: uploads
|
||||
emptyDir: {}
|
||||
{{- end }}
|
||||
{{- with .Values.extraVolumes }}
|
||||
{{- toYaml . | nindent 8 }}
|
||||
{{- end }}
|
||||
{{- with .Values.nodeSelector }}
|
||||
nodeSelector:
|
||||
{{- toYaml . | nindent 8 }}
|
||||
{{- end }}
|
||||
{{- with .Values.affinity }}
|
||||
affinity:
|
||||
{{- toYaml . | nindent 8 }}
|
||||
{{- end }}
|
||||
{{- with .Values.tolerations }}
|
||||
tolerations:
|
||||
{{- toYaml . | nindent 8 }}
|
||||
{{- end }}
|
||||
43
charts/norish/templates/ingress.yaml
Normal file
43
charts/norish/templates/ingress.yaml
Normal file
@ -0,0 +1,43 @@
|
||||
{{- if .Values.ingress.enabled -}}
|
||||
apiVersion: networking.k8s.io/v1
|
||||
kind: Ingress
|
||||
metadata:
|
||||
name: {{ include "norish.fullname" . }}
|
||||
labels:
|
||||
{{- include "norish.labels" . | nindent 4 }}
|
||||
{{- with .Values.ingress.annotations }}
|
||||
annotations:
|
||||
{{- toYaml . | nindent 4 }}
|
||||
{{- end }}
|
||||
spec:
|
||||
{{- if .Values.ingress.className }}
|
||||
ingressClassName: {{ .Values.ingress.className }}
|
||||
{{- end }}
|
||||
{{- if .Values.ingress.tls }}
|
||||
tls:
|
||||
{{- range .Values.ingress.tls }}
|
||||
- hosts:
|
||||
{{- range .hosts }}
|
||||
- {{ . | quote }}
|
||||
{{- end }}
|
||||
{{- if .secretName }}
|
||||
secretName: {{ .secretName }}
|
||||
{{- end }}
|
||||
{{- end }}
|
||||
{{- end }}
|
||||
rules:
|
||||
{{- range .Values.ingress.hosts }}
|
||||
- host: {{ .host | quote }}
|
||||
http:
|
||||
paths:
|
||||
{{- range .paths }}
|
||||
- path: {{ .path }}
|
||||
pathType: {{ .pathType }}
|
||||
backend:
|
||||
service:
|
||||
name: {{ include "norish.fullname" $ }}
|
||||
port:
|
||||
number: {{ $.Values.service.port }}
|
||||
{{- end }}
|
||||
{{- end }}
|
||||
{{- end }}
|
||||
22
charts/norish/templates/pvc.yaml
Normal file
22
charts/norish/templates/pvc.yaml
Normal file
@ -0,0 +1,22 @@
|
||||
{{- if and .Values.persistence.enabled (not .Values.persistence.existingClaim) }}
|
||||
apiVersion: v1
|
||||
kind: PersistentVolumeClaim
|
||||
metadata:
|
||||
name: {{ include "norish.fullname" . }}-uploads
|
||||
labels:
|
||||
{{- include "norish.labels" . | nindent 4 }}
|
||||
app.kubernetes.io/component: app
|
||||
{{- with .Values.persistence.annotations }}
|
||||
annotations:
|
||||
{{- toYaml . | nindent 4 }}
|
||||
{{- end }}
|
||||
spec:
|
||||
accessModes:
|
||||
- {{ .Values.persistence.accessMode }}
|
||||
{{- if .Values.persistence.storageClass }}
|
||||
storageClassName: {{ .Values.persistence.storageClass }}
|
||||
{{- end }}
|
||||
resources:
|
||||
requests:
|
||||
storage: {{ .Values.persistence.size }}
|
||||
{{- end }}
|
||||
32
charts/norish/templates/secret.yaml
Normal file
32
charts/norish/templates/secret.yaml
Normal file
@ -0,0 +1,32 @@
|
||||
apiVersion: v1
|
||||
kind: Secret
|
||||
metadata:
|
||||
name: {{ include "norish.fullname" . }}-secret
|
||||
labels:
|
||||
{{- include "norish.labels" . | nindent 4 }}
|
||||
type: Opaque
|
||||
stringData:
|
||||
{{- if not .Values.config.masterKey.existingSecret }}
|
||||
master-key: {{ .Values.config.masterKey.value | required "config.masterKey.value is required when config.masterKey.existingSecret is not set" | quote }}
|
||||
{{- end }}
|
||||
{{- if not .Values.database.existingSecret }}
|
||||
database-url: {{ include "norish.databaseUrl" . | quote }}
|
||||
{{- end }}
|
||||
{{- if .Values.config.auth.oidc.enabled }}
|
||||
{{- if not .Values.config.auth.oidc.existingSecret }}
|
||||
oidc-client-id: {{ .Values.config.auth.oidc.clientId | quote }}
|
||||
oidc-client-secret: {{ .Values.config.auth.oidc.clientSecret | quote }}
|
||||
{{- end }}
|
||||
{{- end }}
|
||||
{{- if .Values.config.auth.github.enabled }}
|
||||
{{- if not .Values.config.auth.github.existingSecret }}
|
||||
github-client-id: {{ .Values.config.auth.github.clientId | quote }}
|
||||
github-client-secret: {{ .Values.config.auth.github.clientSecret | quote }}
|
||||
{{- end }}
|
||||
{{- end }}
|
||||
{{- if .Values.config.auth.google.enabled }}
|
||||
{{- if not .Values.config.auth.google.existingSecret }}
|
||||
google-client-id: {{ .Values.config.auth.google.clientId | quote }}
|
||||
google-client-secret: {{ .Values.config.auth.google.clientSecret | quote }}
|
||||
{{- end }}
|
||||
{{- end }}
|
||||
20
charts/norish/templates/service.yaml
Normal file
20
charts/norish/templates/service.yaml
Normal file
@ -0,0 +1,20 @@
|
||||
apiVersion: v1
|
||||
kind: Service
|
||||
metadata:
|
||||
name: {{ include "norish.fullname" . }}
|
||||
labels:
|
||||
{{- include "norish.labels" . | nindent 4 }}
|
||||
app.kubernetes.io/component: app
|
||||
{{- with .Values.service.annotations }}
|
||||
annotations:
|
||||
{{- toYaml . | nindent 4 }}
|
||||
{{- end }}
|
||||
spec:
|
||||
type: {{ .Values.service.type }}
|
||||
ports:
|
||||
- port: {{ .Values.service.port }}
|
||||
targetPort: http
|
||||
protocol: TCP
|
||||
name: http
|
||||
selector:
|
||||
{{- include "norish.selectorLabels" . | nindent 4 }}
|
||||
Reference in New Issue
Block a user