mirror of
https://github.com/kataras/iris.git
synced 2025-12-20 19:37:03 +00:00
Read https://github.com/kataras/iris/tree/master/HISTORY.md
This commit is contained in:
@@ -2,19 +2,19 @@ package iriscontrol
|
||||
|
||||
// for the main server
|
||||
func (i *irisControlPlugin) StartServer() {
|
||||
if i.station.Server().IsListening() == false {
|
||||
if i.station.Server().IsSecure() {
|
||||
if i.station.HTTPServer.IsListening() == false {
|
||||
if i.station.HTTPServer.IsSecure() {
|
||||
//listen with ListenTLS
|
||||
i.station.ListenTLS(i.station.Server().Config.ListeningAddr, i.station.Server().Config.CertFile, i.station.Server().Config.KeyFile)
|
||||
i.station.ListenTLS(i.station.Config.Server.ListeningAddr, i.station.Config.Server.CertFile, i.station.Config.Server.KeyFile)
|
||||
} else {
|
||||
//listen normal
|
||||
i.station.Listen(i.station.Server().Config.ListeningAddr)
|
||||
i.station.Listen(i.station.Config.Server.ListeningAddr)
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
func (i *irisControlPlugin) StopServer() {
|
||||
if i.station.Server().IsListening() {
|
||||
if i.station.HTTPServer.IsListening() {
|
||||
i.station.Close()
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user