Skip to content

Commit f07a3ff

Browse files
committed
fix(notify_push): improve after review - change notifyPush.redisURLEnv to notifyPush.extraEnv
Signed-off-by: WrenIX <[email protected]>
1 parent af879f0 commit f07a3ff

File tree

3 files changed

+30
-33
lines changed

3 files changed

+30
-33
lines changed

charts/nextcloud/README.md

Lines changed: 24 additions & 24 deletions
Original file line numberDiff line numberDiff line change
@@ -506,32 +506,32 @@ The nextcloud deployment includes a series of different probes you can use to de
506506
We include an optional Client Push [nextcloud/notify_push](https://github.com/nextcloud/notify_push).
507507

508508

509-
| Parameter | Description | Default |
510-
|----------------------------------------|-------------------------------------------------------------------------------------------------------------------------------------|------------------------|
511-
| `notifyPush.enabled` | Enable another deployment to handle notify_push (sometimes called ClientPush) | `false` |
512-
| `notifyPush.autoSetup` | Setup notify_push on nextcloud per docker-entrypoint-hooks before start | `false` |
513-
| `notifyPush.replicaCount` | Number of notify-push pod replicas to deploy | `1` |
514-
| `notifyPush.image.registry` | notify-push image registry | `docker.io` |
515-
| `notifyPush.image.repository` | notify-push image name | `miles170/notify_push` |
516-
| `notifyPush.image.tag` | notify-push image tag | `v0.7.0` |
517-
| `notifyPush.image.pullPolicy` | notify-push image pull policy | `IfNotPresent` |
518-
| `notifyPush.image.pullSecrets` | notify-push image pull secrets | `[]` |
519-
| `notifyPush.redisURLEnv` | option to set the redis_url per env (if a external redis is used) e.g.: `value: ""` or `valueFrom: {secretKeyRef:{name:"",key:""}}` | `""` |
520-
| `notifyPush.podAnnotations` | Additional annotations for notify-push pods | `{}` |
521-
| `notifyPush.podLabels` | Additional labels for notify-push pods | `{}` |
522-
| `notifyPush.podSecurityContext` | Optional security context for the notify-push pod | `nil` |
523-
| `notifyPush.securityContext` | Optional security context for the notify-push container | `nil` |
524-
| `notifyPush.resources` | notify-push resources | `{}` |
525-
| `notifyPush.service.type` | notify-push: Kubernetes Service type | `ClusterIP` |
526-
| `notifyPush.service.loadBalancerIP` | Use serviceLoadBalancerIP to request a specific static IP, otherwise leave blank | `nil` |
527-
| `notifyPush.service.nodePort` | notify-push: NodePort for service type NodePort | `nil` |
528-
| `notifyPush.service.annotations` | Additional annotations for service notify-push | `{}` |
529-
| `notifyPush.service.labels` | Additional labels for service notify-push | `{}` |
530-
| `notifyPush.ingress.path` | Add path in default ingress to notify_push service | `/push` |
531-
| `notifyPush.ingress.pathType` | PathType for additional path in default ingress for notify-push path | `Prefix` |
509+
| Parameter | Description | Default |
510+
|----------------------------------------|----------------------------------------------------------------------------------|------------------------|
511+
| `notifyPush.enabled` | Enable another deployment to handle notify_push (sometimes called ClientPush) | `false` |
512+
| `notifyPush.autoSetup` | Setup notify_push on nextcloud per docker-entrypoint-hooks before start | `false` |
513+
| `notifyPush.replicaCount` | Number of notify-push pod replicas to deploy | `1` |
514+
| `notifyPush.image.registry` | notify-push image registry | `docker.io` |
515+
| `notifyPush.image.repository` | notify-push image name | `miles170/notify_push` |
516+
| `notifyPush.image.tag` | notify-push image tag | `v0.7.0` |
517+
| `notifyPush.image.pullPolicy` | notify-push image pull policy | `IfNotPresent` |
518+
| `notifyPush.image.pullSecrets` | notify-push image pull secrets | `[]` |
519+
| `notifyPush.extraEnv` | option additional env (if a external redis is used, you need to set REDIS_URL) | `""` |
520+
| `notifyPush.podAnnotations` | Additional annotations for notify-push pods | `{}` |
521+
| `notifyPush.podLabels` | Additional labels for notify-push pods | `{}` |
522+
| `notifyPush.podSecurityContext` | Optional security context for the notify-push pod | `nil` |
523+
| `notifyPush.securityContext` | Optional security context for the notify-push container | `nil` |
524+
| `notifyPush.resources` | notify-push resources | `{}` |
525+
| `notifyPush.service.type` | notify-push: Kubernetes Service type | `ClusterIP` |
526+
| `notifyPush.service.loadBalancerIP` | Use serviceLoadBalancerIP to request a specific static IP, otherwise leave blank | `nil` |
527+
| `notifyPush.service.nodePort` | notify-push: NodePort for service type NodePort | `nil` |
528+
| `notifyPush.service.annotations` | Additional annotations for service notify-push | `{}` |
529+
| `notifyPush.service.labels` | Additional labels for service notify-push | `{}` |
530+
| `notifyPush.ingress.path` | Add path in default ingress to notify_push service | `/push` |
531+
| `notifyPush.ingress.pathType` | PathType for additional path in default ingress for notify-push path | `Prefix` |
532532

533533
> [!Note]
534-
> notify-push needs an redis (redis.enabled=true or notifyPush.redisURLEnv={...})
534+
> notify-push needs an redis (`redis.enabled=true` or `notifyPush.extraEnv=[{name:"REDIS_URL",...}]` )
535535

536536
### Collabora Configuration
537537

charts/nextcloud/templates/notify_push/deployment.yaml

Lines changed: 4 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -47,17 +47,14 @@ spec:
4747
- name: METRICS_PORT
4848
value: "9867"
4949
{{- include "nextcloud.env.database" . | nindent 12 }}
50-
{{- with .Values.notifyPush.redisURLEnv }}
51-
- name: "REDIS_URL"
52-
{{- toYaml . | nindent 14 }}
53-
{{- else }}
54-
{{- if not .Values.redis.enabled }}
55-
{{- fail "notify-push needs an redis (redis.enabled=true or notifyPush.redisURLEnv={...})" }}
56-
{{- end }}
50+
{{- if .Values.redis.enabled }}
5751
{{- include "nextcloud.env.redis" . | nindent 12 }}
5852
{{- end }}
5953
- name: NEXTCLOUD_URL # deployment.namespace.svc.cluster.local
6054
value: "http{{ if .Values.notifyPush.https }}s{{ end }}://{{ template "nextcloud.fullname" . }}.{{ .Release.Namespace }}.svc.cluster.local:{{ .Values.service.port }}"
55+
{{- with .Values.notifyPush.extraEnv }}
56+
{{- toYaml . | nindent 12 }}
57+
{{- end }}
6158
ports:
6259
- name: http
6360
containerPort: 7867

charts/nextcloud/values.yaml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -724,9 +724,9 @@ notifyPush:
724724
# @section -- Notify Push (Clientpush)
725725
pullSecrets: []
726726

727-
# -- option to set the redis_url per env (if a external redis is used) e.g.: `value: ""` or `valueFrom: {secretKeyRef:{name:"",key:""}}`
727+
# -- option additional env (if a external redis is used, you need to set REDIS_URL)
728728
# @section -- Notify Push (Clientpush)
729-
redisURLEnv:
729+
extraEnv: []
730730

731731
# -- Additional annotations for notify-push pods
732732
# @section -- Notify Push (Clientpush)

0 commit comments

Comments
 (0)