1
0

Chrooting.

This commit is contained in:
Alexander Andreev 2022-02-08 23:08:03 +04:00
parent a78001bf22
commit a9a82868ca
Signed by: Arav
GPG Key ID: 1327FE8A374CC86F

View File

@ -47,6 +47,12 @@ func main() {
log.Fatalln(err) log.Fatalln(err)
} }
if config.Chroot != "" {
if err := syscall.Chroot(config.Chroot); err != nil {
log.Fatalln("failed to chroot:", err)
}
}
if err := substituteUser(config.User); err != nil { if err := substituteUser(config.User); err != nil {
log.Fatalln(err) log.Fatalln(err)
} }