mirror of
https://github.com/genuinetools/reg.git
synced 2024-09-12 06:11:03 -04:00
13 lines
255 B
Go
13 lines
255 B
Go
![]() |
// +build !windows,!linux
|
||
|
|
||
|
package chrootarchive // import "github.com/docker/docker/pkg/chrootarchive"
|
||
|
|
||
|
import "golang.org/x/sys/unix"
|
||
|
|
||
|
func chroot(path string) error {
|
||
|
if err := unix.Chroot(path); err != nil {
|
||
|
return err
|
||
|
}
|
||
|
return unix.Chdir("/")
|
||
|
}
|