mirror of
https://github.com/grafana/grafana.git
synced 2025-02-25 18:55:37 -06:00
Unified Storage: Configure client to use tls=preferred (#91162)
* optionally set tls=preferred in the mysql connection string from env var
This commit is contained in:
parent
9ad9b4989b
commit
2362e79e4e
@ -24,6 +24,10 @@ func getEngineMySQL(getter *sectionGetter, _ trace.Tracer) (*xorm.Engine, error)
|
||||
// See: https://dev.mysql.com/doc/refman/en/sql-mode.html
|
||||
"@@SESSION.sql_mode": "ANSI",
|
||||
}
|
||||
tls := getter.String("db_tls")
|
||||
if tls != "" {
|
||||
config.Params["tls"] = tls
|
||||
}
|
||||
config.Collation = "utf8mb4_unicode_ci"
|
||||
config.Loc = time.UTC
|
||||
config.AllowNativePasswords = true
|
||||
|
Loading…
Reference in New Issue
Block a user