Skip to content

Commit

Permalink
fix: Bootrapping improved
Browse files Browse the repository at this point in the history
  • Loading branch information
gonzalezzfelipe committed Aug 30, 2024
1 parent 443f23c commit 51922ba
Show file tree
Hide file tree
Showing 4 changed files with 10 additions and 11 deletions.
10 changes: 5 additions & 5 deletions bootstrap/pgbouncer/main.tf
Original file line number Diff line number Diff line change
Expand Up @@ -27,7 +27,7 @@ variable "load_balancer" {
}

variable "certs_configmap_name" {
type = string
type = string
default = "pgbouncer-certs"
}

Expand All @@ -41,22 +41,22 @@ variable "pg_bouncer_user_settings" {
}

variable "pg_bouncer_auth_user_password" {
type = string
type = string
default = ""
}

variable "postgres_secret_name" {
type = string
type = string
default = ""
}

variable "instance_role" {
type = string
type = string
default = "pgbouncer"
}

variable "postgres_instance_name" {
type = string
type = string
default = "postgres-dbsync-v3-ar9"
}

Expand Down
2 changes: 1 addition & 1 deletion bootstrap/pgbouncer/pg-bouncer.tf
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@ resource "kubernetes_deployment_v1" "pgbouncer" {
}

spec {
replicas = 1
replicas = var.pg_bouncer_replicas

strategy {
rolling_update {
Expand Down
3 changes: 1 addition & 2 deletions bootstrap/postgres/postgres.tf
Original file line number Diff line number Diff line change
Expand Up @@ -84,9 +84,8 @@ resource "kubernetes_stateful_set_v1" "postgres" {
}

volume_mount {
mount_path = "/etc/postgresql/postgresql.conf"
mount_path = "/etc/postgresql"
name = "config"
sub_path = "postgresql.conf"
}

volume_mount {
Expand Down
6 changes: 3 additions & 3 deletions bootstrap/postgres/postgresql.conf
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
listen_addresses = '*'
max_connections = 100
shared_buffers = 12GB
effective_cache_size = 36GB
max_connections = 125
shared_buffers = 15GB
effective_cache_size = 45GB
maintenance_work_mem = 2GB
checkpoint_completion_target = 0.9
wal_buffers = 16MB
Expand Down

0 comments on commit 51922ba

Please sign in to comment.