Skip to content
This repository has been archived by the owner on Nov 17, 2023. It is now read-only.

Commit

Permalink
Remove subpaths to allow config reload (#46)
Browse files Browse the repository at this point in the history
Signed-off-by: Antoine Bardoux <antoine.b@padoa-group.com>
  • Loading branch information
Pluggi authored Oct 18, 2021
1 parent 7a2c2db commit 82db31b
Show file tree
Hide file tree
Showing 2 changed files with 9 additions and 5 deletions.
2 changes: 1 addition & 1 deletion pgbouncer/templates/_pgbouncer.ini.tpl
Original file line number Diff line number Diff line change
Expand Up @@ -48,7 +48,7 @@ unix_socket_dir = var/run/postgresql

auth_type = {{ .Values.settings.auth_type }}
;auth_file = /8.0/main/global/pg_auth
auth_file = /etc/pgbouncer/userlist.txt
auth_file = /etc/pgbouncer.d/userlist.txt
;auth_hba_file =

{{- with .Values.settings.auth_query }}
Expand Down
12 changes: 8 additions & 4 deletions pgbouncer/templates/deployment-pgbouncer.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -62,9 +62,15 @@ spec:
- name: userssecret
secret:
secretName: {{ template "pgbouncer.usersSecretName" . }}
items:
- key: {{ template "pgbouncer.usersSecretKey" . }}
path: userlist.txt
- name: config
configMap:
name: {{ template "pgbouncer.fullname" . }}-config
items:
- key: pgbouncer.ini
path: pgbouncer.ini
{{- with .Values.imagePullSecrets }}
imagePullSecrets:
{{- toYaml . | nindent 8 }}
Expand All @@ -89,12 +95,10 @@ spec:
command: ["/bin/sh","-c","sleep 5"]
volumeMounts:
- name: userssecret
subPath: {{ template "pgbouncer.usersSecretKey" . }}
mountPath: /etc/pgbouncer/userlist.txt
mountPath: /etc/pgbouncer.d
readOnly: true
- name: config
subPath: pgbouncer.ini
mountPath: /etc/pgbouncer/pgbouncer.ini
mountPath: /etc/pgbouncer
readOnly: true
resources:
{{- toYaml .Values.resources | nindent 12 }}
Expand Down

0 comments on commit 82db31b

Please sign in to comment.