Skip to content

Commit 208bd83

Browse files
committed
Fix pgx echo sample app attempting to use TLS for db connection
1 parent 853770c commit 208bd83

1 file changed

Lines changed: 1 addition & 1 deletion

File tree

  • sample-apps/echo-pgx-sql

sample-apps/echo-pgx-sql/db.go

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -80,7 +80,7 @@ func connectToDb() *sql.DB {
8080
var err error
8181
var db *sql.DB
8282
// Connect to PostgreSQL
83-
connStr := "postgresql://localhost:5432/db?user=user&password=password"
83+
connStr := "postgresql://localhost:5432/db?user=user&password=password&sslmode=disable"
8484
db, err = sql.Open("pgx", connStr)
8585
if err != nil {
8686
log.Fatal(err)

0 commit comments

Comments
 (0)