Skip to content

Commit

Permalink
changing back to ssl require
Browse files Browse the repository at this point in the history
  • Loading branch information
pspalmirasara authored Sep 10, 2024
1 parent 95be0fb commit 29ac29f
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/infra/db/database/database.go
Original file line number Diff line number Diff line change
Expand Up @@ -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))
Expand Down

0 comments on commit 29ac29f

Please sign in to comment.