mirror of
https://github.com/acepanel/panel.git
synced 2026-02-04 19:37:18 +08:00
33 lines
334 B
Go
33 lines
334 B
Go
package bootstrap
|
|
|
|
import (
|
|
"runtime/debug"
|
|
)
|
|
|
|
func boot() {
|
|
debug.SetGCPercent(10)
|
|
debug.SetMemoryLimit(64 << 20)
|
|
|
|
initConf()
|
|
initGlobal()
|
|
initLogger()
|
|
initOrm()
|
|
runMigrate()
|
|
}
|
|
|
|
func BootWeb() {
|
|
boot()
|
|
initValidator()
|
|
initSession()
|
|
initCron()
|
|
initQueue()
|
|
initHttp()
|
|
|
|
select {}
|
|
}
|
|
|
|
func BootCli() {
|
|
boot()
|
|
initCli()
|
|
}
|