mirror of
https://gitee.com/rainbond/Rainbond.git
synced 2024-12-02 03:37:46 +08:00
[FIX] confused nginx upstream
This commit is contained in:
parent
32dc844b43
commit
499bebf3fe
@ -100,7 +100,7 @@ func Run(s *option.GWServer) error {
|
||||
logrus.Info("RBD app gateway start success!")
|
||||
|
||||
term := make(chan os.Signal)
|
||||
signal.Notify(term, os.Interrupt, syscall.SIGTERM)
|
||||
signal.Notify(term, os.Interrupt, syscall.SIGTERM, syscall.SIGQUIT)
|
||||
select {
|
||||
case <-term:
|
||||
logrus.Warn("Received SIGTERM, exiting gracefully...")
|
||||
|
@ -243,7 +243,8 @@ func (n *NginxConfigFileTemplete) WriteServer(c option.Config, configtype, tenan
|
||||
}
|
||||
n.writeLocks[tenant].Lock()
|
||||
defer n.writeLocks[tenant].Unlock()
|
||||
serverConfigFile := path.Join(n.configFileDirPath, configtype, tenant, "servers.conf")
|
||||
filename := fmt.Sprintf("%s_servers.conf", tenant)
|
||||
serverConfigFile := path.Join(n.configFileDirPath, configtype, tenant, filename)
|
||||
first := true
|
||||
if servers == nil || len(servers) < 1 {
|
||||
logrus.Warnf("%s proxy is empty, nginx server[%s] will clean up", tenant, serverConfigFile)
|
||||
|
@ -160,10 +160,10 @@ http {
|
||||
}
|
||||
}
|
||||
}
|
||||
include http/*/*.conf;
|
||||
include http/*/*_servers.conf;
|
||||
}
|
||||
|
||||
stream {
|
||||
include stream/*/upstreams.conf;
|
||||
include stream/*/servers.conf;
|
||||
include stream/*/*_servers.conf;
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user