service

package
v0.0.0-...-851e5e8 Latest Latest
Warning

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

Go to latest
Published: Mar 28, 2024 License: GPL-3.0 Imports: 17 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

View Source
var ErrNotStarted = errors.New("norduserd wasn't started")

ErrNotStarted when disabling norduser

Functions

This section is empty.

Types

type ChildProcessNorduser

type ChildProcessNorduser struct {
	// contains filtered or unexported fields
}

ChildProcessNorduser manages norduser service through exec.Command

func NewChildProcessNorduser

func NewChildProcessNorduser() *ChildProcessNorduser

func (*ChildProcessNorduser) Enable

func (f *ChildProcessNorduser) Enable(uid uint32, gid uint32) (err error)

Enable starts norduser process

func (*ChildProcessNorduser) Stop

func (f *ChildProcessNorduser) Stop(uid uint32) error

Stop teminates norduser process

type Combined

type Combined struct {
	// contains filtered or unexported fields
}

func NewNorduserService

func NewNorduserService() *Combined

func (*Combined) Disable

func (c *Combined) Disable(uid uint32) error

func (*Combined) DisableAll

func (c *Combined) DisableAll()

func (*Combined) Enable

func (c *Combined) Enable(uid uint32, gid uint32) error

func (*Combined) Stop

func (c *Combined) Stop(uid uint32) error

func (*Combined) StopAll

func (c *Combined) StopAll()

type NorduserFileshareClient

type NorduserFileshareClient interface {
	StartFileshare(uid uint32) error
	StopFileshare(uid uint32) error
}

type NorduserGRPCClient

type NorduserGRPCClient struct {
}

func NewNorduserGRPCClient

func NewNorduserGRPCClient() NorduserGRPCClient

func (NorduserGRPCClient) StartFileshare

func (n NorduserGRPCClient) StartFileshare(uid uint32) error

func (NorduserGRPCClient) StopFileshare

func (n NorduserGRPCClient) StopFileshare(uid uint32) error

type NorduserService

type NorduserService interface {
	Enable(uid uint32, gid uint32) error
	Disable(uid uint32) error
	Stop(uid uint32) error
	StopAll()
	DisableAll()
}

type NorduserSnap

type NorduserSnap struct{}

func NewNorduserSnapService

func NewNorduserSnapService() NorduserSnap

func (NorduserSnap) Disable

func (n NorduserSnap) Disable(uid uint32) error

func (NorduserSnap) DisableAll

func (n NorduserSnap) DisableAll()

func (NorduserSnap) Enable

func (n NorduserSnap) Enable(uint32, uint32) error

func (NorduserSnap) Stop

func (n NorduserSnap) Stop(uid uint32) error

func (NorduserSnap) StopAll

func (n NorduserSnap) StopAll()

type SystemdNorduser

type SystemdNorduser struct{}

SystemdNorduser manages norduser service through systemctl

func (*SystemdNorduser) Disable

func (*SystemdNorduser) Disable(uid uint32) error

Disable and stop norduser service

func (*SystemdNorduser) Enable

func (*SystemdNorduser) Enable(uid uint32) error

Enable and start norduser service

func (*SystemdNorduser) Stop

func (*SystemdNorduser) Stop(uid uint32) error

Stop without disabling

Jump to

Keyboard shortcuts

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