Index: perf/go/skiaperf/main.go |
diff --git a/perf/go/skiaperf/main.go b/perf/go/skiaperf/main.go |
index 2640e17251bf1e52e7cef0335d3ee3f3fe355ae9..df76f0a5f7b6c06ac1876efa7abc016b10c43d3c 100644 |
--- a/perf/go/skiaperf/main.go |
+++ b/perf/go/skiaperf/main.go |
@@ -24,6 +24,7 @@ import ( |
import ( |
"skia.googlesource.com/buildbot.git/go/common" |
+ "skia.googlesource.com/buildbot.git/go/database" |
"skia.googlesource.com/buildbot.git/go/gitinfo" |
"skia.googlesource.com/buildbot.git/go/login" |
"skia.googlesource.com/buildbot.git/go/metadata" |
@@ -1058,9 +1059,16 @@ func makeResourceHandler() func(http.ResponseWriter, *http.Request) { |
} |
func main() { |
+ // Setup DB flags. |
+ database.SetupFlags(db.PROD_DB_HOST, db.PROD_DB_PORT, database.USER_RW, db.PROD_DB_NAME) |
+ |
common.InitWithMetrics("skiaperf", *graphiteServer) |
Init() |
- db.Init(db.ProdDatabaseConfig(*local)) |
+ conf, err := database.ConfigFromFlagsAndMetadata(*local, db.MigrationSteps()) |
+ if err != nil { |
+ glog.Fatal(err) |
+ } |
+ db.Init(conf) |
stats.Start(nanoTileStore, git) |
alerting.Start(nanoTileStore, *apikey) |