添加跨域名
This commit is contained in:
parent
f5b3fedee3
commit
e16222849c
|
@ -15,7 +15,7 @@ func main() {
|
|||
var c config.Config
|
||||
conf.MustLoad(*configFile, &c)
|
||||
|
||||
server := rest.MustNewServer(c.RestConf)
|
||||
server := rest.MustNewServer(c.RestConf, rest.WithCors())
|
||||
defer server.Stop()
|
||||
|
||||
ctx := svc.NewServiceContext(c)
|
||||
|
|
|
@ -15,7 +15,7 @@ func main() {
|
|||
var c config.Config
|
||||
conf.MustLoad(*configFile, &c)
|
||||
|
||||
server := rest.MustNewServer(c.RestConf)
|
||||
server := rest.MustNewServer(c.RestConf, rest.WithCors())
|
||||
defer server.Stop()
|
||||
|
||||
ctx := svc.NewServiceContext(c)
|
||||
|
|
|
@ -20,7 +20,7 @@ func main() {
|
|||
var c config.Config
|
||||
conf.MustLoad(*configFile, &c)
|
||||
|
||||
server := rest.MustNewServer(c.RestConf)
|
||||
server := rest.MustNewServer(c.RestConf, rest.WithCors())
|
||||
defer server.Stop()
|
||||
|
||||
ctx := svc.NewServiceContext(c)
|
||||
|
|
|
@ -20,7 +20,7 @@ func main() {
|
|||
var c config.Config
|
||||
conf.MustLoad(*configFile, &c)
|
||||
|
||||
server := rest.MustNewServer(c.RestConf)
|
||||
server := rest.MustNewServer(c.RestConf, rest.WithCors())
|
||||
defer server.Stop()
|
||||
|
||||
ctx := svc.NewServiceContext(c)
|
||||
|
|
|
@ -19,7 +19,7 @@ func main() {
|
|||
var c config2.Config
|
||||
conf.MustLoad(*configFile, &c)
|
||||
|
||||
server := rest.MustNewServer(c.RestConf)
|
||||
server := rest.MustNewServer(c.RestConf, rest.WithCors())
|
||||
defer server.Stop()
|
||||
|
||||
ctx := svc2.NewServiceContext(c)
|
||||
|
|
|
@ -20,7 +20,7 @@ func main() {
|
|||
var c config.Config
|
||||
conf.MustLoad(*configFile, &c)
|
||||
|
||||
server := rest.MustNewServer(c.RestConf)
|
||||
server := rest.MustNewServer(c.RestConf, rest.WithCors())
|
||||
defer server.Stop()
|
||||
|
||||
ctx := svc.NewServiceContext(c)
|
||||
|
|
|
@ -20,7 +20,7 @@ func main() {
|
|||
var c config.Config
|
||||
conf.MustLoad(*configFile, &c)
|
||||
|
||||
server := rest.MustNewServer(c.RestConf)
|
||||
server := rest.MustNewServer(c.RestConf, rest.WithCors())
|
||||
defer server.Stop()
|
||||
|
||||
ctx := svc.NewServiceContext(c)
|
||||
|
|
|
@ -20,7 +20,7 @@ func main() {
|
|||
var c config.Config
|
||||
conf.MustLoad(*configFile, &c)
|
||||
|
||||
server := rest.MustNewServer(c.RestConf)
|
||||
server := rest.MustNewServer(c.RestConf, rest.WithCors())
|
||||
defer server.Stop()
|
||||
|
||||
ctx := svc.NewServiceContext(c)
|
||||
|
|
|
@ -20,7 +20,7 @@ func main() {
|
|||
var c config.Config
|
||||
conf.MustLoad(*configFile, &c)
|
||||
|
||||
server := rest.MustNewServer(c.RestConf)
|
||||
server := rest.MustNewServer(c.RestConf, rest.WithCors())
|
||||
defer server.Stop()
|
||||
|
||||
ctx := svc.NewServiceContext(c)
|
||||
|
|
|
@ -20,7 +20,7 @@ func main() {
|
|||
var c config.Config
|
||||
conf.MustLoad(*configFile, &c)
|
||||
|
||||
server := rest.MustNewServer(c.RestConf)
|
||||
server := rest.MustNewServer(c.RestConf, rest.WithCors())
|
||||
defer server.Stop()
|
||||
|
||||
ctx := svc.NewServiceContext(c)
|
||||
|
|
|
@ -20,7 +20,7 @@ func main() {
|
|||
var c config.Config
|
||||
conf.MustLoad(*configFile, &c)
|
||||
|
||||
server := rest.MustNewServer(c.RestConf)
|
||||
server := rest.MustNewServer(c.RestConf, rest.WithCors())
|
||||
defer server.Stop()
|
||||
|
||||
ctx := svc.NewServiceContext(c)
|
||||
|
|
|
@ -20,7 +20,7 @@ func main() {
|
|||
var c config.Config
|
||||
conf.MustLoad(*configFile, &c)
|
||||
|
||||
server := rest.MustNewServer(c.RestConf)
|
||||
server := rest.MustNewServer(c.RestConf, rest.WithCors())
|
||||
defer server.Stop()
|
||||
ctx := svc.NewServiceContext(c)
|
||||
handler.RegisterHandlers(server, ctx)
|
||||
|
|
|
@ -20,7 +20,7 @@ func main() {
|
|||
var c config.Config
|
||||
conf.MustLoad(*configFile, &c)
|
||||
|
||||
server := rest.MustNewServer(c.RestConf)
|
||||
server := rest.MustNewServer(c.RestConf, rest.WithCors())
|
||||
defer server.Stop()
|
||||
|
||||
ctx := svc.NewServiceContext(c)
|
||||
|
|
|
@ -20,7 +20,7 @@ func main() {
|
|||
var c config.Config
|
||||
conf.MustLoad(*configFile, &c)
|
||||
|
||||
server := rest.MustNewServer(c.RestConf)
|
||||
server := rest.MustNewServer(c.RestConf, rest.WithCors())
|
||||
defer server.Stop()
|
||||
|
||||
ctx := svc.NewServiceContext(c)
|
||||
|
|
|
@ -20,7 +20,7 @@ func main() {
|
|||
var c config.Config
|
||||
conf.MustLoad(*configFile, &c)
|
||||
|
||||
server := rest.MustNewServer(c.RestConf)
|
||||
server := rest.MustNewServer(c.RestConf, rest.WithCors())
|
||||
defer server.Stop()
|
||||
|
||||
ctx := svc.NewServiceContext(c)
|
||||
|
|
Loading…
Reference in New Issue
Block a user