Skip to content

Commit d99c255

Browse files
committed
explicit environ credentials for SLO over GORM
1 parent 7b92edf commit d99c255

File tree

1 file changed

+4
-0
lines changed

1 file changed

+4
-0
lines changed

tests/slo/gorm/storage.go

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -4,6 +4,7 @@ import (
44
"context"
55
"database/sql"
66
"fmt"
7+
environ "github.com/ydb-platform/ydb-go-sdk-auth-environ"
78
"time"
89

910
ydb "github.com/ydb-platform/gorm-driver"
@@ -62,6 +63,9 @@ func NewStorage(cfg *config.Config, poolSize int) (*Storage, error) {
6263
ydb.WithMaxOpenConns(poolSize),
6364
ydb.WithMaxIdleConns(poolSize),
6465
ydb.WithTablePathPrefix(label),
66+
ydb.With(
67+
environ.WithEnvironCredentials(),
68+
),
6569
),
6670
&gorm.Config{
6771
Logger: gormLogger.Default.LogMode(gormLogger.Warn),

0 commit comments

Comments
 (0)