Skip to content

Commit

Permalink
Fix errors
Browse files Browse the repository at this point in the history
  • Loading branch information
andrii-korotkov-verkada committed Dec 30, 2024
1 parent d28bbe6 commit a689d11
Show file tree
Hide file tree
Showing 3 changed files with 7 additions and 6 deletions.
2 changes: 1 addition & 1 deletion chart/templates/pgbouncer/pgbouncer-deployment.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -202,7 +202,7 @@ spec:
{{- if .Values.pgbouncer.extraContainers }}
{{- tpl (toYaml .Values.pgbouncer.extraContainers) . | nindent 8 }}
{{- end }}
{{- if or .Values.pgbouncer.mountConfigSecret Values.pgbouncer.ssl.ca .Values.pgbouncer.ssl.cert .Values.pgbouncer.ssl.key .Values.volumes .Values.pgbouncer.extraVolumes }}
{{- if or .Values.pgbouncer.mountConfigSecret .Values.pgbouncer.ssl.ca .Values.pgbouncer.ssl.cert .Values.pgbouncer.ssl.key .Values.volumes .Values.pgbouncer.extraVolumes }}
volumes:
{{- if .Values.pgbouncer.mountConfigSecret }}
- name: pgbouncer-config
Expand Down
4 changes: 2 additions & 2 deletions chart/values.schema.json
Original file line number Diff line number Diff line change
Expand Up @@ -7022,7 +7022,7 @@
}
},
"labels": {
"description": "Labels to add to the pgbouncer objects and pods.",
"description": "Labels to add to the PgBouncer objects and pods.",
"type": "object",
"default": {},
"additionalProperties": {
Expand Down Expand Up @@ -7085,7 +7085,7 @@
"default": null
},
"mountConfigSecret": {
"description": "Whether to mount the config secret files under /etc/pgbouncer/ by default.",
"description": "Whether to mount the config secret files under `/etc/pgbouncer/` by default.",
"type": "boolean",
"x-docsSection": "Common",
"default": true
Expand Down
7 changes: 4 additions & 3 deletions helm_tests/other/test_pgbouncer.py
Original file line number Diff line number Diff line change
Expand Up @@ -410,8 +410,8 @@ def test_should_add_component_specific_labels(self):
},
show_only=["templates/pgbouncer/pgbouncer-deployment.yaml"],
)
assert "labels" in jmespath.search("metadata", docs[0])
assert jmespath.search("metadata.labels", docs[0])["test_label"] == "test_label_value"
assert "labels" in jmespath.search("spec.template.metadata", docs[0])
assert jmespath.search("spec.template.metadata.labels", docs[0])["test_label"] == "test_label_value"


class TestPgbouncerConfig:
Expand Down Expand Up @@ -620,7 +620,8 @@ def test_no_config_secret_mount(self):
)

spec = jmespath.search("spec.template.spec", docs[0])
assert spec is not None and "volumes" not in spec
assert spec is not None
assert "volumes" not in spec


class TestPgbouncerExporter:
Expand Down

0 comments on commit a689d11

Please sign in to comment.