From 847440c8cfe88011e61512c4f022ad288d5cc422 Mon Sep 17 00:00:00 2001 From: Greg Dubicki <566632+gdubicki@users.noreply.github.com> Date: Thu, 10 Oct 2024 07:40:14 +0100 Subject: [PATCH] Fix for passing pool configs as false as when using `default` the value `false` was treated as, well, falsy, and the default value of `true` was applied... See https://github.com/helm/helm/issues/3308 and https://stackoverflow.com/q/66265193/2693875 for more context --- charts/pgcat/templates/secret.yaml | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/charts/pgcat/templates/secret.yaml b/charts/pgcat/templates/secret.yaml index 358f4e97..8db46900 100644 --- a/charts/pgcat/templates/secret.yaml +++ b/charts/pgcat/templates/secret.yaml @@ -48,9 +48,9 @@ stringData: load_balancing_mode = {{ default "random" $pool.load_balancing_mode | quote }} default_role = {{ default "any" $pool.default_role | quote }} prepared_statements_cache_size = {{ default 500 $pool.prepared_statements_cache_size }} - query_parser_enabled = {{ default true $pool.query_parser_enabled }} - query_parser_read_write_splitting = {{ default true $pool.query_parser_read_write_splitting }} - primary_reads_enabled = {{ default true $pool.primary_reads_enabled }} + query_parser_enabled = {{ ne $pool.query_parser_enabled false }} + query_parser_read_write_splitting = {{ ne $pool.query_parser_read_write_splitting false }} + primary_reads_enabled = {{ ne $pool.primary_reads_enabled false }} sharding_function = {{ default "pg_bigint_hash" $pool.sharding_function | quote }} {{- range $index, $user := $pool.users }}