28 lines
521 B
Go
28 lines
521 B
Go
package server
|
|
|
|
import (
|
|
cssw "git.loafle.net/commons/server-go/socket/web"
|
|
"git.loafle.net/overflow/member_gateway_rpc/config"
|
|
"git.loafle.net/overflow/probe_gateway_rpc/servlet"
|
|
)
|
|
|
|
func New(_config *config.Config) *cssw.Server {
|
|
|
|
as := &servlet.AuthServlets{}
|
|
ps := &servlet.ProbeServlets{}
|
|
|
|
sh := &ServerHandlers{
|
|
ServerHandlers: *_config.ServerHandler,
|
|
Config: _config,
|
|
}
|
|
|
|
sh.RegisterServlet("/auth", as)
|
|
sh.RegisterServlet("/probe", ps)
|
|
|
|
s := &cssw.Server{
|
|
ServerHandler: sh,
|
|
}
|
|
|
|
return s
|
|
}
|