You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
21 lines
353 B
21 lines
353 B
//go:build windows
|
|
// +build windows
|
|
|
|
package core
|
|
|
|
import (
|
|
"net/http"
|
|
"time"
|
|
|
|
"github.com/gin-gonic/gin"
|
|
)
|
|
|
|
func initServer(address string, router *gin.Engine) server {
|
|
return &http.Server{
|
|
Addr: address,
|
|
Handler: router,
|
|
ReadTimeout: 20 * time.Second,
|
|
WriteTimeout: 20 * time.Second,
|
|
MaxHeaderBytes: 1 << 20,
|
|
}
|
|
}
|