Corteza no longer defaults to MySQL db
Default DB_DSN changed from mysql://corteza:corteza@tcp(db:3306)/corteza?collation=utf8mb4_general_ci to sqlite3://file::memory:?cache=shared&mode=memory
This commit is contained in:
+2
-6
@@ -2,7 +2,6 @@ package options
|
||||
|
||||
import (
|
||||
"strings"
|
||||
"time"
|
||||
)
|
||||
|
||||
type (
|
||||
@@ -12,16 +11,13 @@ type (
|
||||
)
|
||||
|
||||
func DB(pfix string) (o *DBOpt) {
|
||||
const delay = 15 * time.Second
|
||||
const maxTries = 100
|
||||
|
||||
o = &DBOpt{
|
||||
DSN: "mysql://corteza:corteza@tcp(db:3306)/corteza?collation=utf8mb4_general_ci",
|
||||
DSN: "sqlite3://file::memory:?cache=shared&mode=memory",
|
||||
}
|
||||
|
||||
fill(o)
|
||||
|
||||
if !strings.Contains(o.DSN, "://") {
|
||||
if o.DSN != "" && !strings.Contains(o.DSN, "://") {
|
||||
// Make sure DSN is compatible with new requirements
|
||||
o.DSN = "mysql://" + o.DSN
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user