osutil

package
v0.7.7 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Jul 19, 2017 License: MIT Imports: 10 Imported by: 2

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func Chroot added in v0.5.0

func Chroot(rootDir string) error

func Cp

func Cp(from, to string) error

func DropCapabilities

func DropCapabilities(keepCaps map[uint]bool) error

func Execv

func Execv(cmd string, args []string, env []string) error

func ExistsDir

func ExistsDir(dir string) bool

func ExistsFile

func ExistsFile(file string) bool

func ForceMount added in v0.5.0

func ForceMount(device, target, mType, options string) error

func IsDirEmpty

func IsDirEmpty(dir string) bool
func IsSymlink(file string) bool

func LookupGroup

func LookupGroup(id string) (int, error)

func LookupUser

func LookupUser(id string) (int, error)

func Mknod

func Mknod(path string, mode uint32, dev int) error

Mknod unless path does not exists.

func MountIfNotMounted added in v0.5.0

func MountIfNotMounted(device, target, mType, options string) error

func RunCmd

func RunCmd(name string, arg ...string) error

func Setgid added in v0.2.2

func Setgid(gid int) (err error)

Setgid sets the gid of the calling thread to the specified gid.

func Setuid added in v0.2.2

func Setuid(uid int) (err error)

Setuid sets the uid of the calling thread to the specified uid.

func Symlink(oldname, newname string) error

Symlink, but ignore already exists file.

Types

This section is empty.

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL