From 29ac29fc3511cb09986e689ab6859576a6376cdb Mon Sep 17 00:00:00 2001 From: pspalmirasara <37162306+pspalmirasara@users.noreply.github.com> Date: Tue, 10 Sep 2024 18:39:00 -0300 Subject: [PATCH] changing back to ssl require --- src/infra/db/database/database.go | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/infra/db/database/database.go b/src/infra/db/database/database.go index c256dea..606cd3b 100644 --- a/src/infra/db/database/database.go +++ b/src/infra/db/database/database.go @@ -38,7 +38,7 @@ func (rdb *RealDatabase) First(dest interface{}, conds ...interface{}) error { } func ConnectDB() { - conectionString := fmt.Sprintf("host=%s user=%s password=%s dbname=%s port=5432 sslmode=disable TimeZone=America/Fortaleza", + conectionString := fmt.Sprintf("host=%s user=%s password=%s dbname=%s port=5432 sslmode=require TimeZone=America/Fortaleza", os.Getenv("POSTGRES_HOST"), os.Getenv("POSTGRES_USER"), os.Getenv("POSTGRES_PASSWORD"), os.Getenv("POSTGRES_DB")) db, err := gorm.Open(postgres.Open(conectionString))