Merge remote-tracking branch 'djjudas21/master'

This commit is contained in:
Alexander "Ace" Olofsson 2021-09-26 20:51:35 +02:00
commit 7036770f81
3 changed files with 37 additions and 12 deletions

View file

@ -4,10 +4,14 @@ appVersion: "1.1.2"
description: A social platform to enjoy and share music
icon: https://funkwhale.audio/favicon.png
name: funkwhale
version: 0.3.10
version: 0.4.0
dependencies:
- name: redis
version: ~10.6.10
repository: https://charts.bitnami.com/bitnami
condition: redis.enabled
- name: postgresql
version: ~10.9.4
repository: https://charts.bitnami.com/bitnami
condition: postgresql.enabled

View file

@ -7,7 +7,19 @@ Expand the name of the chart.
{{- end -}}
{{- define "funkwhale.dbUrl" -}}
postgres://{{ .Values.database.user }}:{{ .Values.database.password }}@{{ .Values.database.host }}:{{ .Values.database.port }}/{{ .Values.database.database }}
{{- if and .Values.postgresql.enabled .Values.postgresql.host -}}
{{ fail "Setting both postgresql.enabled and postgresql.host will deploy an internal Postgres service and attempt to use an external one - please set only one of the two!" }}
{{- else if .Values.postgresql.enabled -}}
postgres://{{ .Values.postgresql.postgresqlUsername }}:{{ .Values.postgresql.postgresqlPassword }}@{{ template "funkwhale.fullname" . }}-postgresql:{{ .Values.postgresql.service.port }}/{{ .Values.postgresql.postgresqlDatabase }}
{{- else if .Values.postgresql.host -}}
postgres://{{ .Values.postgresql.postgresqlUsername }}:{{ .Values.postgresql.postgresqlPassword }}@{{ .Values.postgresql.host }}:{{ .Values.postgresql.service.port }}/{{ .Values.postgresql.postgresqlDatabase }}
{{- else -}}
{{ fail "Either postgresql.enabled or postgresql.host are required!" }}
{{- end -}}
{{- end -}}
{{- if .Values.database.user -}}
{{ fail "You are using the old database config key - please migrate to the new postgresql config key" }}
{{- end -}}
{{/*

View file

@ -30,21 +30,31 @@ ingress:
# hosts:
# - chart-example.local
database:
## Database host
host:
postgresql:
# If you already have a Postgresql service you'd like to use, set
# this to false and adjust the host to use your existing service.
enabled: true
## Database port
port: 5432
## Database host
host: ""
## Database user
user: funkwhale
postgresqlUsername: postgres
## Database password
password:
postgresqlPassword: funkwhale
## Database name
database: funkwhale
## Database password
postgresqlDatabase: funkwhale
## Database port
service:
port: 5432
persistence:
enabled: true
# storageClass: ""
# size: 8Gi
redis:
# If you already have a Redis service you'd like to use, set
@ -240,4 +250,3 @@ celery:
# operator: In
# values:
# - app