Merge branch 'master' of gitlab.com:ananace/charts
This commit is contained in:
commit
651ccc6c27
6 changed files with 61 additions and 13 deletions
|
@ -10,3 +10,4 @@ dependencies:
|
||||||
- name: redis
|
- name: redis
|
||||||
version: ~10.6.10
|
version: ~10.6.10
|
||||||
repository: https://charts.bitnami.com/bitnami
|
repository: https://charts.bitnami.com/bitnami
|
||||||
|
condition: redis.enabled
|
||||||
|
|
|
@ -10,10 +10,6 @@ Expand the name of the chart.
|
||||||
postgres://{{ .Values.database.user }}:{{ .Values.database.password }}@{{ .Values.database.host }}:{{ .Values.database.port }}/{{ .Values.database.database }}
|
postgres://{{ .Values.database.user }}:{{ .Values.database.password }}@{{ .Values.database.host }}:{{ .Values.database.port }}/{{ .Values.database.database }}
|
||||||
{{- end -}}
|
{{- end -}}
|
||||||
|
|
||||||
{{- define "funkwhale.redisUrl" -}}
|
|
||||||
redis://:{{ .Values.redis.password }}@{{ .Values.redis.host | default (printf "%s-%s" (include "funkwhale.fullname" .) "redis-master") }}:{{ .Values.redis.redisPort }}/0
|
|
||||||
{{- end -}}
|
|
||||||
|
|
||||||
{{/*
|
{{/*
|
||||||
Create a default fully qualified app name.
|
Create a default fully qualified app name.
|
||||||
We truncate at 63 chars because some Kubernetes name fields are limited to this (by the DNS naming spec).
|
We truncate at 63 chars because some Kubernetes name fields are limited to this (by the DNS naming spec).
|
||||||
|
@ -45,3 +41,15 @@ Create the correct image tag name
|
||||||
{{- define "funkwhale.imageTag" -}}
|
{{- define "funkwhale.imageTag" -}}
|
||||||
{{- .Values.image.tag | default .Chart.AppVersion -}}
|
{{- .Values.image.tag | default .Chart.AppVersion -}}
|
||||||
{{- end -}}
|
{{- end -}}
|
||||||
|
|
||||||
|
{{- define "funkwhale.redisUrl" -}}
|
||||||
|
{{- if and .Values.redis.enabled .Values.redis.host -}}
|
||||||
|
{{ fail "Setting both redis.enabled and redis.host will deploy an internal Redis service and attempt to use an external one - please set only one of the two!" }}
|
||||||
|
{{- else if .Values.redis.enabled -}}
|
||||||
|
redis://:{{ .Values.redis.password }}@{{ template "funkwhale.fullname" . }}-redis-master:{{ .Values.redis.redisPort }}/0
|
||||||
|
{{- else if .Values.redis.host -}}
|
||||||
|
redis://:{{ .Values.redis.password }}@{{ .Values.redis.host }}:{{ .Values.redis.redisPort }}/0
|
||||||
|
{{- else -}}
|
||||||
|
{{ fail "Either redis.enabled or redis.host are required!" }}
|
||||||
|
{{- end -}}
|
||||||
|
{{- end -}}
|
||||||
|
|
|
@ -52,6 +52,17 @@ spec:
|
||||||
command:
|
command:
|
||||||
- stat
|
- stat
|
||||||
- /run/funkwhale/funkwhale.sock
|
- /run/funkwhale/funkwhale.sock
|
||||||
|
failureThreshold: {{ .Values.api.readinessProbe.failureThreshold | default 3 }}
|
||||||
|
periodSeconds: {{ .Values.api.readinessProbe.periodSeconds | default 5 }}
|
||||||
|
initialDelaySeconds: {{ .Values.api.readinessProbe.initialDelaySeconds | default 5 }}
|
||||||
|
startupProbe:
|
||||||
|
exec:
|
||||||
|
command:
|
||||||
|
- stat
|
||||||
|
- /run/funkwhale/funkwhale.sock
|
||||||
|
failureThreshold: {{ .Values.api.startupProbe.failureThreshold | default 3 }}
|
||||||
|
periodSeconds: {{ .Values.api.startupProbe.periodSeconds | default 20 }}
|
||||||
|
initialDelaySeconds: {{ .Values.api.startupProbe.initialDelaySeconds | default 5 }}
|
||||||
envFrom:
|
envFrom:
|
||||||
- configMapRef:
|
- configMapRef:
|
||||||
name: {{ include "funkwhale.fullname" . }}
|
name: {{ include "funkwhale.fullname" . }}
|
||||||
|
@ -97,9 +108,21 @@ spec:
|
||||||
httpGet:
|
httpGet:
|
||||||
path: /
|
path: /
|
||||||
port: http
|
port: http
|
||||||
|
failureThreshold: {{ .Values.front.livenessProbe.failureThreshold | default 3 }}
|
||||||
|
periodSeconds: {{ .Values.front.livenessProbe.periodSeconds | default 20 }}
|
||||||
|
initialDelaySeconds: {{ .Values.front.livenessProbe.initialDelaySeconds | default 15 }}
|
||||||
readinessProbe:
|
readinessProbe:
|
||||||
tcpSocket:
|
tcpSocket:
|
||||||
port: http
|
port: http
|
||||||
|
failureThreshold: {{ .Values.front.readinessProbe.failureThreshold | default 3 }}
|
||||||
|
periodSeconds: {{ .Values.front.readinessProbe.periodSeconds | default 5 }}
|
||||||
|
initialDelaySeconds: {{ .Values.front.readinessProbe.initialDelaySeconds | default 5 }}
|
||||||
|
startupProbe:
|
||||||
|
tcpSocket:
|
||||||
|
port: http
|
||||||
|
failureThreshold: {{ .Values.front.startupProbe.failureThreshold | default 3 }}
|
||||||
|
periodSeconds: {{ .Values.front.startupProbe.periodSeconds | default 20 }}
|
||||||
|
initialDelaySeconds: {{ .Values.front.startupProbe.initialDelaySeconds | default 5 }}
|
||||||
volumeMounts:
|
volumeMounts:
|
||||||
- mountPath: /run/funkwhale
|
- mountPath: /run/funkwhale
|
||||||
name: funkwhale-sock
|
name: funkwhale-sock
|
||||||
|
|
|
@ -1,3 +1,5 @@
|
||||||
|
{{- $secret := (lookup "v1" "Secret" .Release.Namespace (include "funkwhale.fullname" .)) -}}
|
||||||
|
|
||||||
apiVersion: v1
|
apiVersion: v1
|
||||||
kind: Secret
|
kind: Secret
|
||||||
metadata:
|
metadata:
|
||||||
|
@ -10,7 +12,11 @@ metadata:
|
||||||
data:
|
data:
|
||||||
CACHE_URL: {{ include "funkwhale.redisUrl" . | b64enc }}
|
CACHE_URL: {{ include "funkwhale.redisUrl" . | b64enc }}
|
||||||
DATABASE_URL: {{ include "funkwhale.dbUrl" . | b64enc }}
|
DATABASE_URL: {{ include "funkwhale.dbUrl" . | b64enc }}
|
||||||
DJANGO_SECRET_KEY: {{ .Values.djangoSecret | b64enc }}
|
{{ if $secret -}}
|
||||||
|
DJANGO_SECRET_KEY: {{ $secret.data.DJANGO_SECRET_KEY }}
|
||||||
|
{{ else -}}
|
||||||
|
DJANGO_SECRET_KEY: {{ (.Values.djangoSecret | default uuidv4) | b64enc }}
|
||||||
|
{{ end }}
|
||||||
|
|
||||||
{{- range $key, $val := .Values.extraSecret }}
|
{{- range $key, $val := .Values.extraSecret }}
|
||||||
{{ $key }}: {{ $val | b64enc }}
|
{{ $key }}: {{ $val | b64enc }}
|
||||||
|
|
|
@ -47,6 +47,14 @@ database:
|
||||||
database: funkwhale
|
database: funkwhale
|
||||||
|
|
||||||
redis:
|
redis:
|
||||||
|
# If you already have a Redis service you'd like to use, set
|
||||||
|
# this to false and adjust the host to use your existing service.
|
||||||
|
enabled: true
|
||||||
|
|
||||||
|
host: ''
|
||||||
|
redisPort: 6379
|
||||||
|
password: 'funkwhale'
|
||||||
|
|
||||||
cluster:
|
cluster:
|
||||||
enabled: false
|
enabled: false
|
||||||
master:
|
master:
|
||||||
|
@ -55,9 +63,6 @@ redis:
|
||||||
slave:
|
slave:
|
||||||
persistence:
|
persistence:
|
||||||
enabled: false
|
enabled: false
|
||||||
password: funkwhale
|
|
||||||
redisPort: 6379
|
|
||||||
# host: {{ template "funkwhale.fullname" . }}-redis-master
|
|
||||||
|
|
||||||
djangoSecret: ''
|
djangoSecret: ''
|
||||||
|
|
||||||
|
@ -122,6 +127,8 @@ api:
|
||||||
tolerations: []
|
tolerations: []
|
||||||
|
|
||||||
affinity: {}
|
affinity: {}
|
||||||
|
readinessProbe: {}
|
||||||
|
startupProbe: {}
|
||||||
|
|
||||||
front:
|
front:
|
||||||
image:
|
image:
|
||||||
|
@ -153,6 +160,9 @@ front:
|
||||||
tolerations: []
|
tolerations: []
|
||||||
|
|
||||||
affinity: {}
|
affinity: {}
|
||||||
|
readinessProbe: {}
|
||||||
|
livenessProbe: {}
|
||||||
|
startupProbe: {}
|
||||||
|
|
||||||
celery:
|
celery:
|
||||||
beat:
|
beat:
|
||||||
|
|
|
@ -159,8 +159,8 @@ synapse:
|
||||||
## Additional environment variables to apply to the main Synapse pod
|
## Additional environment variables to apply to the main Synapse pod
|
||||||
##
|
##
|
||||||
extraEnv: {}
|
extraEnv: {}
|
||||||
# - name: USE_JEMALLOC
|
# - name: LD_PRELOAD
|
||||||
# value: "1"
|
# value: /usr/lib/x86_64-linux-gnu/libjemalloc.so.2
|
||||||
# - name: SYNAPSE_CACHE_FACTOR
|
# - name: SYNAPSE_CACHE_FACTOR
|
||||||
# value: "2"
|
# value: "2"
|
||||||
|
|
||||||
|
@ -263,8 +263,8 @@ workers:
|
||||||
## Additional environment variables to add to the worker.
|
## Additional environment variables to add to the worker.
|
||||||
##
|
##
|
||||||
extraEnv: {}
|
extraEnv: {}
|
||||||
# - name: USE_JEMALLOC
|
# - name: LD_PRELOAD
|
||||||
# value: "1"
|
# value: /usr/lib/x86_64-linux-gnu/libjemalloc.so.2
|
||||||
# - name: SYNAPSE_CACHE_FACTOR
|
# - name: SYNAPSE_CACHE_FACTOR
|
||||||
# value: "1.0"
|
# value: "1.0"
|
||||||
|
|
||||||
|
|
Loading…
Reference in a new issue