models/server: add dashboard for frps by gin

This commit is contained in:
fatedier
2016-05-19 00:04:19 +08:00
parent ea323084ad
commit f404a0a5ee
5 changed files with 82 additions and 2 deletions

View File

@@ -111,6 +111,15 @@ func main() {
}
}
// create dashboard web server if DashboardPort != 0
if server.DashboardPort != 0 {
err := server.RunDashboardServer(server.BindAddr, server.DashboardPort)
if err != nil {
log.Error("Create dashboard web server error, %v", err)
os.Exit(1)
}
}
log.Info("Start frps success")
ProcessControlConn(l)
}