linux_user

package
v0.0.39 Latest Latest
Warning

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

Go to latest
Published: Mar 3, 2023 License: MIT Imports: 6 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func AddToGroup added in v0.0.28

func AddToGroup(userName string, groupName string) error

func Create

func Create(userName string, userId int, options ...LinuxUserCreateOptions) error

func Exists

func Exists(userName string) bool

Types

type LinuxUser

type LinuxUser struct {
	ID            int
	Name          string
	GroupId       int
	HomeDirectory string
	Shell         string
}

func Get

func Get(userName string) (*LinuxUser, error)

func Marshal

func Marshal(value string) (*LinuxUser, error)

type LinuxUserCreateOptions

type LinuxUserCreateOptions struct {
	Key   string
	Value string
}

func UserGroupCreateOption

func UserGroupCreateOption(groupName string) LinuxUserCreateOptions

func UserHomeDirectoryCreateOption

func UserHomeDirectoryCreateOption(path string) LinuxUserCreateOptions

Jump to

Keyboard shortcuts

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