add mariadb as an option for installing pixelfed

This commit is contained in:
jessebot
2025-01-23 22:33:57 +01:00
parent c0803306bf
commit c0cc5b9280
3 changed files with 56 additions and 15 deletions
+7 -1
View File
@@ -69,7 +69,13 @@ A Helm chart for deploying Pixelfed on Kubernetes
| ingress.hosts[0].paths[0].pathType | string | `"ImplementationSpecific"` | | | ingress.hosts[0].paths[0].pathType | string | `"ImplementationSpecific"` | |
| ingress.tls | list | `[]` | | | ingress.tls | list | `[]` | |
| livenessProbe | object | `{}` | This is to setup the liveness probe more information can be found here: https://kubernetes.io/docs/tasks/configure-pod-container/configure-liveness-readiness-startup-probes/ | | livenessProbe | object | `{}` | This is to setup the liveness probe more information can be found here: https://kubernetes.io/docs/tasks/configure-pod-container/configure-liveness-readiness-startup-probes/ |
| mariadb.enabled | bool | `false` | enable mariadb subchart - currently experiemental for this chart read more about the values here: https://github.com/bitnami/charts/tree/main/bitnami/mariadb | | mariadb.auth.database | string | `"pixelfed"` | Name for a custom database to create |
| mariadb.auth.existingSecret | string | `"new-password-secret"` | Use existing secret for password details (auth.rootPassword, auth.password, auth.replicationPassword will be ignored and picked up from this secret). The secret has to contain the keys mariadb-root-password, mariadb-replication-password and mariadb-password |
| mariadb.auth.password | string | `"newUserPassword123"` | Password for the new user. Ignored if existing secret is provided |
| mariadb.auth.replicationPassword | string | `"newReplicationPassword123"` | MariaDB replication user password. Ignored if existing secret is provided |
| mariadb.auth.rootPassword | string | `"newRootPassword123"` | Password for the root user. Ignored if existing secret is provided. |
| mariadb.auth.username | string | `"pixelfed"` | Name for a custom user to create |
| mariadb.enabled | bool | `false` | enable mariadb subchart - currently experimental for this chart read more about the values: https://github.com/bitnami/charts/tree/main/bitnami/mariadb |
| nameOverride | string | `""` | This is to override the chart name. | | nameOverride | string | `""` | This is to override the chart name. |
| nodeSelector | object | `{}` | put the pixelfed pod on a specific node/nodegroup | | nodeSelector | object | `{}` | put the pixelfed pod on a specific node/nodegroup |
| phpConfigs | object | `{}` | PHP Configuration files Will be injected in /usr/local/etc/php-fpm.d | | phpConfigs | object | `{}` | PHP Configuration files Will be injected in /usr/local/etc/php-fpm.d |
@@ -129,6 +129,12 @@ data:
DB_USERNAME: postgres DB_USERNAME: postgres
DB_DATABASE: postgres DB_DATABASE: postgres
{{- end }} {{- end }}
{{- if .Values.mariadb.enabled }}
DB_PORT: {{ .Values.mariadb.primary.service.ports.mysql | quote }}
DB_HOST: {{ .Values.mariadb.fullnameOverride }}
DB_USERNAME: {{ .Values.mariadb.auth.username }}
DB_DATABASE: {{ .Values.mariadb.auth.database }}
{{- end }}
# valkey (redis) # valkey (redis)
{{- if .Values.valkey.enabled }} {{- if .Values.valkey.enabled }}
+43 -14
View File
@@ -2,10 +2,12 @@
# This is a YAML-formatted file. # This is a YAML-formatted file.
# Declare variables to be passed into your templates. # Declare variables to be passed into your templates.
# -- This will set the replicaset count more information can be found here: https://kubernetes.io/docs/concepts/workloads/controllers/replicaset/ # -- This will set the replicaset count more information can be found here:
# https://kubernetes.io/docs/concepts/workloads/controllers/replicaset/
replicaCount: 1 replicaCount: 1
# This sets the container image more information can be found here: https://kubernetes.io/docs/concepts/containers/images/ # This sets the container image more information can be found here:
# https://kubernetes.io/docs/concepts/containers/images/
image: image:
registry: ghcr.io registry: ghcr.io
# -- you can see the source [ghcr.io/mattlqx/docker-pixelfed](https://ghcr.io/mattlqx/docker-pixelfed) # -- you can see the source [ghcr.io/mattlqx/docker-pixelfed](https://ghcr.io/mattlqx/docker-pixelfed)
@@ -17,7 +19,9 @@ image:
# so please either pin a sha tag or use dev-nging as the tag) # so please either pin a sha tag or use dev-nging as the tag)
tag: "7d1d62c8552683225456c2a552ba8ca36afb24b32f706e425310de5bf84aeab1" tag: "7d1d62c8552683225456c2a552ba8ca36afb24b32f706e425310de5bf84aeab1"
# -- This is for the secretes for pulling an image from a private repository more information can be found here: https://kubernetes.io/docs/tasks/configure-pod-container/pull-image-private-registry/ # -- This is for the secretes for pulling an image from a private repository
# more information can be found here:
# https://kubernetes.io/docs/tasks/configure-pod-container/pull-image-private-registry/
imagePullSecrets: [] imagePullSecrets: []
# -- This is to override the chart name. # -- This is to override the chart name.
@@ -35,7 +39,8 @@ extraEnv: []
# -- template out extra environment variables e.g. from ConfigMaps or Secrets # -- template out extra environment variables e.g. from ConfigMaps or Secrets
extraEnvFrom: [] extraEnvFrom: []
# This section builds out the service account more information can be found here: https://kubernetes.io/docs/concepts/security/service-accounts/ # This section builds out the service account more information can be found here:
# https://kubernetes.io/docs/concepts/security/service-accounts/
serviceAccount: serviceAccount:
# -- Specifies whether a service account should be created # -- Specifies whether a service account should be created
create: true create: true
@@ -48,11 +53,13 @@ serviceAccount:
name: "" name: ""
# -- This is for setting Kubernetes Annotations to a Pod. # -- This is for setting Kubernetes Annotations to a Pod.
# For more information checkout: https://kubernetes.io/docs/concepts/overview/working-with-objects/annotations/ # For more information checkout:
# https://kubernetes.io/docs/concepts/overview/working-with-objects/annotations/
podAnnotations: {} podAnnotations: {}
# -- This is for setting Kubernetes Labels to a Pod. # -- This is for setting Kubernetes Labels to a Pod.
# For more information checkout: https://kubernetes.io/docs/concepts/overview/working-with-objects/labels/ # For more information checkout:
# https://kubernetes.io/docs/concepts/overview/working-with-objects/labels/
podLabels: {} podLabels: {}
# securityContext for the whole pixelfed pod # securityContext for the whole pixelfed pod
@@ -74,11 +81,14 @@ securityContext:
# drop: # drop:
# - ALL # - ALL
# This is for setting up a service more information can be found here: https://kubernetes.io/docs/concepts/services-networking/service/ # This is for setting up a service more information can be found here:
# https://kubernetes.io/docs/concepts/services-networking/service/
service: service:
# -- This sets the service type more information can be found here: https://kubernetes.io/docs/concepts/services-networking/service/#publishing-services-service-types # -- This sets the service type more information can be found here:
# https://kubernetes.io/docs/concepts/services-networking/service/#publishing-services-service-types
type: ClusterIP type: ClusterIP
# -- This sets the ports more information can be found here: https://kubernetes.io/docs/concepts/services-networking/service/#field-spec-ports # -- This sets the ports more information can be found here:
# https://kubernetes.io/docs/concepts/services-networking/service/#field-spec-ports
port: 80 port: 80
# -- Port to attach to on the pods. Also sets what port nginx listens on inside the container. # -- Port to attach to on the pods. Also sets what port nginx listens on inside the container.
targetPort: 8080 targetPort: 8080
@@ -112,21 +122,24 @@ resources: {}
# memory: 128Mi # memory: 128Mi
# -- This is to setup the liveness probe # -- This is to setup the liveness probe
# more information can be found here: https://kubernetes.io/docs/tasks/configure-pod-container/configure-liveness-readiness-startup-probes/ # more information can be found here:
# https://kubernetes.io/docs/tasks/configure-pod-container/configure-liveness-readiness-startup-probes/
livenessProbe: {} livenessProbe: {}
# httpGet: # httpGet:
# path: /api/service/health-check # path: /api/service/health-check
# port: http # port: http
# -- This is to setup the readiness probe # -- This is to setup the readiness probe
# more information can be found here: https://kubernetes.io/docs/tasks/configure-pod-container/configure-liveness-readiness-startup-probes/ # more information can be found here:
# https://kubernetes.io/docs/tasks/configure-pod-container/configure-liveness-readiness-startup-probes/
readinessProbe: {} readinessProbe: {}
# httpGet: # httpGet:
# path: /api/service/health-check # path: /api/service/health-check
# port: http # port: http
autoscaling: autoscaling:
# -- enable autoscaling. more information can be found [here](https://kubernetes.io/docs/concepts/workloads/autoscaling/) # -- enable autoscaling. more information can be found
# [here](https://kubernetes.io/docs/concepts/workloads/autoscaling/)
enabled: false enabled: false
# -- minimum replicas to always keep up # -- minimum replicas to always keep up
minReplicas: 1 minReplicas: 1
@@ -589,6 +602,22 @@ pixelfed:
secret_access_key: "" secret_access_key: ""
mariadb: mariadb:
# -- enable mariadb subchart - currently experiemental for this chart # -- enable mariadb subchart - currently experimental for this chart
# read more about the values here: https://github.com/bitnami/charts/tree/main/bitnami/mariadb # read more about the values: https://github.com/bitnami/charts/tree/main/bitnami/mariadb
enabled: false enabled: false
auth:
# -- Name for a custom database to create
database: "pixelfed"
# -- Name for a custom user to create
username: "pixelfed"
# -- Password for the root user. Ignored if existing secret is provided.
rootPassword: "newRootPassword123"
# -- Password for the new user. Ignored if existing secret is provided
password: "newUserPassword123"
# -- MariaDB replication user password. Ignored if existing secret is provided
replicationPassword: "newReplicationPassword123"
# -- Use existing secret for password details (auth.rootPassword,
# auth.password, auth.replicationPassword will be ignored and picked up
# from this secret). The secret has to contain the keys mariadb-root-password,
# mariadb-replication-password and mariadb-password
existingSecret: new-password-secret