mirror of
https://github.com/AdguardTeam/AdGuardHome.git
synced 2024-11-30 04:19:28 +03:00
479675b6cc
Setting debug.SetGCPercent makes golang free memory faster. This greatly improves overall RSS usage. Otherwise, golang prefers not to free memory at all:)
18 lines
307 B
Go
18 lines
307 B
Go
package main
|
|
|
|
import (
|
|
"runtime/debug"
|
|
|
|
"github.com/AdguardTeam/AdGuardHome/home"
|
|
)
|
|
|
|
// version will be set through ldflags, contains current version
|
|
var version = "undefined"
|
|
|
|
// channel can be set via ldflags
|
|
var channel = "release"
|
|
|
|
func main() {
|
|
debug.SetGCPercent(10)
|
|
home.Main(version, channel)
|
|
}
|