Add config.php support

This commit is contained in:
Guilhem Lavaux 2024-12-05 08:12:27 +01:00
parent bb85f1e71d
commit 5835c67019
3 changed files with 21 additions and 2 deletions

View File

@ -4,8 +4,8 @@ name: basic-web-app
PullName: basic-app-puller PullName: basic-app-puller
description: A basic Helm chart to have PHP webapps in Kubernetes. It supports webhook for pulling from gitea description: A basic Helm chart to have PHP webapps in Kubernetes. It supports webhook for pulling from gitea
type: application type: application
version: 2.1.2 version: 2.2.0
appVersion: "2.1.2" appVersion: "2.2.0"
dependencies: dependencies:
- name: postgresql - name: postgresql

View File

@ -54,6 +54,12 @@ spec:
volumeMounts: volumeMounts:
- name: data - name: data
mountPath: "/var/www/html" mountPath: "/var/www/html"
{{- if not (eq "" .Values.config-web.path) }}
- name: config
mountPath: {{ printf "/var/www/html/%s" .Values.config-web.path }}
readOnly: true
subPath: {{ .Values.config-web.key }}
{{- end}}
env: env:
{{- with .Values.env.plain }} {{- with .Values.env.plain }}
{{- toYaml . | nindent 12 }} {{- toYaml . | nindent 12 }}
@ -149,3 +155,11 @@ spec:
secretName: {{ .Values.updater.ssh.secretName }} secretName: {{ .Values.updater.ssh.secretName }}
defaultMode: 0400 defaultMode: 0400
{{- end }} {{- end }}
{{- if not (eq "" .Values.config-web.path) }}
- name: config
secret:
secretName: {{ .Values.config-web.secretName }}
items:
- key: {{ .Values.config-web.key }}
path: {{ .Values.config-web.key }}
{{- end }}

View File

@ -11,6 +11,11 @@ mysql:
postgresql: postgresql:
enabled: false enabled: false
config-web:
path: ""
key: ""
secretName: ""
updater: updater:
image: image:
repository: glvx/web-updater repository: glvx/web-updater