- CHANGE: 优化`proxy`核心模块, 使用Chuncked Buffer传输数据, 减少内存占用
- REMOVE: caddy
- REMOVE: nocache
- CHANGE: 优化前端页面
This commit is contained in:
WJQSERVER 2025-01-19 22:00:10 +08:00 committed by GitHub
parent beb441f0b0
commit c393191b93
No known key found for this signature in database
GPG key ID: B5690EEEBB952194
27 changed files with 596 additions and 559 deletions

View file

@ -91,11 +91,16 @@ func setupRateLimit(cfg *config.Config) {
}
}
func initBufferSize() {
proxy.InitChunkedBufferSize(cfg.Server.BufferSize)
}
func init() {
readFlag()
flag.Parse()
loadConfig()
setupLogger(cfg)
initBufferSize()
loadlist(cfg)
setupRateLimit(cfg)
@ -145,6 +150,8 @@ func init() {
router.NoRoute(func(c *gin.Context) {
proxy.NoRouteHandler(cfg, limiter, iplimiter, runMode)(c)
})
fmt.Printf("GHProxy Version: %s\n", version)
}
func main() {