Move auth account creation to config/cmd (#1676)

This commit is contained in:
ben-toogood
2020-06-03 09:43:20 +01:00
committed by Dominic Wong
parent f45cdba9ba
commit fde1aa9d6a
2 changed files with 71 additions and 71 deletions

View File

@@ -17,7 +17,6 @@ import (
"github.com/micro/go-micro/v2/plugin"
"github.com/micro/go-micro/v2/server"
"github.com/micro/go-micro/v2/store"
authutil "github.com/micro/go-micro/v2/util/auth"
signalutil "github.com/micro/go-micro/v2/util/signal"
"github.com/micro/go-micro/v2/util/wrapper"
)
@@ -176,11 +175,6 @@ func (s *service) Stop() error {
}
func (s *service) Run() error {
// generate an auth account
if err := authutil.Generate(s.Server().Options().Id, s.Name(), s.Options().Auth); err != nil {
return err
}
// register the debug handler
s.opts.Server.Handle(
s.opts.Server.NewHandler(