From 9d1b012de027df1ec5a8c9e3961fec885d3b0747 Mon Sep 17 00:00:00 2001 From: trivernis Date: Wed, 20 Dec 2023 11:10:36 +0100 Subject: [PATCH] Add pooling config to ignore additional startup params --- apps/sharkey/app.yaml | 1 + apps/sharkey/app/stackgres-pooling.yaml | 12 ++++++++++++ apps/sharkey/app/stackgres.yaml | 2 ++ 3 files changed, 15 insertions(+) create mode 100644 apps/sharkey/app/stackgres-pooling.yaml diff --git a/apps/sharkey/app.yaml b/apps/sharkey/app.yaml index a544876..719152f 100644 --- a/apps/sharkey/app.yaml +++ b/apps/sharkey/app.yaml @@ -10,5 +10,6 @@ resources: - app/config.yaml - app/volume.yaml - app/stackgres-scripts.yaml + - app/stackgres-pooling.yaml - app/stackgres.yaml - app/deploy.yaml diff --git a/apps/sharkey/app/stackgres-pooling.yaml b/apps/sharkey/app/stackgres-pooling.yaml new file mode 100644 index 0000000..e746cf7 --- /dev/null +++ b/apps/sharkey/app/stackgres-pooling.yaml @@ -0,0 +1,12 @@ +apiVersion: stackgres.io/v1 +kind: SGPoolingConfig +metadata: + name: pgbouncerconf + namespace: sharkey +spec: + pgBouncer: + pgbouncer.ini: + pgbouncer: + max_client_conn: '2000' + default_pool_size: '50' + ignore_startup_parameters: statement_timeout diff --git a/apps/sharkey/app/stackgres.yaml b/apps/sharkey/app/stackgres.yaml index 5646efd..03225f4 100644 --- a/apps/sharkey/app/stackgres.yaml +++ b/apps/sharkey/app/stackgres.yaml @@ -12,6 +12,8 @@ spec: size: '50Gi' storageClass: ebs-ssd prometheusAutobind: true + configurations: + sgPoolingConfig: pgbouncerconf managedSql: scripts: - sgScript: cluster-scripts