Skip to content

Commit

Permalink
Merge branch 'main' into fix-missing-env-vars
Browse files Browse the repository at this point in the history
Signed-off-by: Jesse Hitch <[email protected]>
  • Loading branch information
jessebot authored Sep 24, 2024
2 parents 96b7502 + 0565cdb commit 78a95e3
Show file tree
Hide file tree
Showing 6 changed files with 72 additions and 22 deletions.
4 changes: 2 additions & 2 deletions charts/nextcloud/Chart.yaml
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
apiVersion: v2
name: nextcloud
version: 5.5.0
appVersion: 29.0.4
version: 6.1.0
appVersion: 30.0.0
description: A file sharing server that puts the control and security of your own data back into your hands.
keywords:
- nextcloud
Expand Down
5 changes: 4 additions & 1 deletion charts/nextcloud/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -119,6 +119,7 @@ The following table lists the configurable parameters of the nextcloud chart and
| `nextcloud.existingSecret.smtpUsernameKey` | Name of the key that contains the SMTP username | `nil` |
| `nextcloud.existingSecret.smtpPasswordKey` | Name of the key that contains the SMTP password | `nil` |
| `nextcloud.existingSecret.smtpHostKey` | Name of the key that contains the SMTP hostname | `nil` |
| `nextcloud.existingSecret.tokenKey` | Name of the key that contains the nextcloud metrics token | `''` |
| `nextcloud.update` | Trigger update if custom command is used | `0` |
| `nextcloud.containerPort` | Customize container port when not running as root | `80` |
| `nextcloud.trustedDomains` | Optional space-separated list of trusted domains | `[]` |
Expand Down Expand Up @@ -238,8 +239,10 @@ If you choose to use one of the prepackaged Bitnami helm charts, you must config
| `mariadb.image.registry` | MariaDB image registry | `docker.io` |
| `mariadb.image.repository` | MariaDB image repository | `bitnami/mariadb` |
| `mariadb.image.tag` | MariaDB image tag | `` |
| `mariadb.global.defaultStorageClass` | MariaDB Global default StorageClass for Persistent Volume(s) | `''` |
| `mariadb.primary.persistence.enabled` | Whether or not to Use a PVC on MariaDB primary | `false` |
| `mariadb.primary.persistence.existingClaim` | Use an existing PVC for MariaDB primary | `nil` |
| `mariadb.primary.persistence.storageClass` | MariaDB primary persistent volume storage Class | `''` |
| `mariadb.primary.persistence.existingClaim` | Use an existing PVC for MariaDB primary | `''` |
| `postgresql.enabled` | Whether to use the PostgreSQL chart | `false` |
| `postgresql.image.registry` | PostgreSQL image registry | `docker.io` |
| `postgresql.image.repository` | PostgreSQL image repository | `bitnami/postgresql` |
Expand Down
2 changes: 1 addition & 1 deletion charts/nextcloud/templates/_helpers.tpl
Original file line number Diff line number Diff line change
Expand Up @@ -317,7 +317,7 @@ S3 as primary object store env vars
- name: OBJECTSTORE_S3_SECRET
value: {{ .Values.nextcloud.objectStore.s3.secretKey | quote }}
{{- end }}
{{- if and .Values.nextcloud.objectStore.s3.existingSecret .Values.nextcloud.objectStore.s3.secretKeys.bucket }}
{{- if and .Values.nextcloud.objectStore.s3.existingSecret .Values.nextcloud.objectStore.s3.secretKeys.sse_c_key }}
- name: OBJECTSTORE_S3_SSE_C_KEY
valueFrom:
secretKeyRef:
Expand Down
25 changes: 21 additions & 4 deletions charts/nextcloud/templates/metrics/deployment.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -40,12 +40,12 @@ spec:
image: "{{ .Values.metrics.image.repository }}:{{ .Values.metrics.image.tag }}"
imagePullPolicy: {{ .Values.metrics.image.pullPolicy }}
env:
{{- if .Values.metrics.token }}
{{- if or .Values.metrics.token .Values.nextcloud.existingSecret.tokenKey }}
- name: NEXTCLOUD_AUTH_TOKEN
valueFrom:
secretKeyRef:
name: {{ .Values.nextcloud.existingSecret.secretName | default (include "nextcloud.fullname" .) }}
key: {{ .Values.nextcloud.existingSecret.tokenKey }}
key: {{ .Values.nextcloud.existingSecret.tokenKey | default "nextcloud-token" }}
{{- else }}
- name: NEXTCLOUD_USERNAME
valueFrom:
Expand Down Expand Up @@ -79,7 +79,24 @@ spec:
resources:
{{- toYaml . | nindent 12 }}
{{- end }}
{{- with .Values.metrics.securityContext }}
securityContext:
runAsUser: 1000
runAsNonRoot: true
{{- toYaml . | nindent 12 }}
{{- end }}
{{- with .Values.metrics.podSecurityContext }}
securityContext:
{{- toYaml . | nindent 12 }}
{{- end }}
{{- with .Values.metrics.affinity }}
affinity:
{{- toYaml . | nindent 8 }}
{{- end }}
{{- with .Values.metrics.tolerations }}
tolerations:
{{- toYaml . | nindent 8 }}
{{- end }}
{{- with .Values.metrics.nodeSelector }}
nodeSelector:
{{- toYaml . | nindent 8 }}
{{- end }}
{{- end }}
6 changes: 3 additions & 3 deletions charts/nextcloud/templates/service.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -32,10 +32,10 @@ spec:
targetPort: {{ .Values.nextcloud.containerPort }}
protocol: TCP
name: http
{{- if (eq .Values.service.type "NodePort") }}
nodePort: {{ .Values.service.nodePort | default "" }}
{{- with .Values.service.nodePort }}
nodePort: {{ . }}
{{- end }}
selector:
app.kubernetes.io/name: {{ include "nextcloud.name" . }}
app.kubernetes.io/instance: {{ .Release.Name }}
app.kubernetes.io/component: app
app.kubernetes.io/component: app
52 changes: 41 additions & 11 deletions charts/nextcloud/values.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -83,7 +83,7 @@ nextcloud:
# secretName: nameofsecret
usernameKey: nextcloud-username
passwordKey: nextcloud-password
tokenKey: nextcloud-token
tokenKey: ""
smtpUsernameKey: smtp-username
smtpPasswordKey: smtp-password
smtpHostKey: smtp-host
Expand Down Expand Up @@ -401,6 +401,11 @@ mariadb:
# To use an ALREADY DEPLOYED mariadb database, set this to false and configure the externalDatabase parameters
enabled: false

# see: https://github.com/bitnami/charts/tree/main/bitnami/mariadb#global-parameters
global:
# overwrites the primary.persistence.storageClass value
defaultStorageClass: ""

auth:
database: nextcloud
username: nextcloud
Expand All @@ -418,8 +423,8 @@ mariadb:
persistence:
enabled: false
# Use an existing Persistent Volume Claim (must be created ahead of time)
# existingClaim: ""
# storageClass: ""
existingClaim: ""
storageClass: ""
accessMode: ReadWriteOnce
size: 8Gi

Expand Down Expand Up @@ -505,7 +510,7 @@ service:
type: ClusterIP
port: 8080
loadBalancerIP: ""
nodePort: nil
nodePort:
annotations: {}
## Insert your annotations such as below
# test/test: pumuckel
Expand Down Expand Up @@ -638,23 +643,48 @@ metrics:
## Metrics exporter resource requests and limits
## ref: http://kubernetes.io/docs/user-guide/compute-resources/
##
# resources: {}
resources: {}

# -- Metrics exporter pod Annotation
podAnnotations: {}

## Metrics exporter pod Annotation and Labels
# podAnnotations: {}
# -- Metrics exporter pod Labels
podLabels: {}

# podLabels: {}
# -- Metrics exporter pod nodeSelector
nodeSelector: {}

# -- Metrics exporter pod tolerations
tolerations: []

# -- Metrics exporter pod affinity
affinity: {}

service:
type: ClusterIP
## Use serviceLoadBalancerIP to request a specific static IP,
## otherwise leave blank
# loadBalancerIP:
# Use serviceLoadBalancerIP to request a specific static IP,
# otherwise leave blank
loadBalancerIP:
annotations:
prometheus.io/scrape: "true"
prometheus.io/port: "9205"
labels: {}

# -- security context for the metrics CONTAINER in the pod
securityContext:
runAsUser: 1000
runAsNonRoot: true
# allowPrivilegeEscalation: false
# capabilities:
# drop:
# - ALL

# -- security context for the metrics POD
podSecurityContext: {}
# runAsNonRoot: true
# seccompProfile:
# type: RuntimeDefault

## Prometheus Operator ServiceMonitor configuration
##
serviceMonitor:
Expand Down

0 comments on commit 78a95e3

Please sign in to comment.