add basic auth for webapi

This commit is contained in:
ginuerzh
2022-02-12 21:05:39 +08:00
parent fdd67a6086
commit f2d806886a
12 changed files with 197 additions and 86 deletions

View File

@ -54,7 +54,7 @@ func createService(ctx *gin.Context) {
return
}
go svc.Run()
go svc.Serve()
cfg := config.Global()
cfg.Services = append(cfg.Services, &req.Data)
@ -115,7 +115,7 @@ func updateService(ctx *gin.Context) {
return
}
go svc.Run()
go svc.Serve()
cfg := config.Global()
for i := range cfg.Services {