Browse Source

Add option to disable Web-UI

pool
Sammy Libre 8 years ago
parent
commit
c1a78f5d3d
  1. 1
      config.example.json
  2. 1
      go-pool/pool/pool.go
  3. 4
      main.go

1
config.example.json

@ -37,6 +37,7 @@
}, },
"frontend": { "frontend": {
"enabled": true,
"listen": "0.0.0.0:8082", "listen": "0.0.0.0:8082",
"login": "admin", "login": "admin",
"password": "", "password": "",

1
go-pool/pool/pool.go

@ -39,6 +39,7 @@ type Upstream struct {
} }
type Frontend struct { type Frontend struct {
Enabled bool `json:"enabled"`
Listen string `json:"listen"` Listen string `json:"listen"`
Login string `json:"login"` Login string `json:"login"`
Password string `json:"password"` Password string `json:"password"`

4
main.go

@ -31,7 +31,9 @@ func startStratum() {
} }
s := stratum.NewStratum(&cfg) s := stratum.NewStratum(&cfg)
go startFrontend(&cfg, s) if cfg.Frontend.Enabled {
startFrontend(&cfg, s)
}
s.Listen() s.Listen()
} }

Loading…
Cancel
Save