s6

package
v0.0.0-...-7ab9190 Latest Latest
Warning

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

Go to latest
Published: Jun 17, 2021 License: AGPL-3.0 Imports: 14 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func SvScanWriteCtlAt

func SvScanWriteCtlAt(fd int, s string) error

func SvcWriteCtlAt

func SvcWriteCtlAt(fd int, s string) error

Types

type Service

type Service int

func OpenService

func OpenService(dir int, name string) (Service, error)

func (Service) Close

func (svc Service) Close() error

func (Service) NotificationFd

func (svc Service) NotificationFd() (int, error)

func (Service) OpenEvent

func (svc Service) OpenEvent() (ftrigr.FtrigR, error)

func (Service) Status

func (svc Service) Status() (SvStatus, error)

func (Service) Svc

func (svc Service) Svc(ctx context.Context, msg string) error

func (Service) WriteConfig

func (svc Service) WriteConfig(s ServiceDefinition) error

type ServiceDefinition

type ServiceDefinition struct {
	Argv           execline.Argv `json:"argv"`
	Envp           []string      `json:"envp"`
	Finish         execline.Argv `json:"finish"`
	Down           bool          `json:"down"`
	NotificationFd uintptr       `json:"notification-fd"`
	CloneNewPID    bool          `json:"clone-newpid"`
	TimeoutKill    uintptr       `json:"timeout-kill"`
	TimeoutFinish  uintptr       `json:"timeout-finish"`
	MaxDeathTally  uintptr       `json:"max-death-tally"`
	DownSignal     uintptr       `json:"down-signal"`
}

func (*ServiceDefinition) UnmarshalJSON

func (svc *ServiceDefinition) UnmarshalJSON(data []byte) error

type SvStatus

type SvStatus struct {
	Pid        uint64         `json:"pid"`
	Wstat      uint16         `json:"wstat"`
	Stamp      djbunix.Tai64N `json:"stamp"`
	ReadyStamp djbunix.Tai64N `json:"readystamp"`
	Paused     bool           `json:"paused"`
	Finishing  bool           `json:"finishing"`
	Want       bool           `json:"want"`
	WantUp     bool           `json:"wantup"`
	Ready      bool           `json:"ready"`
	Throttled  bool           `json:"throttled"`
}

func (*SvStatus) UnmarshalBinary

func (sv *SvStatus) UnmarshalBinary(pack []byte) error

type SvscanScripts

type SvscanScripts struct {
	SigTerm  execline.Argv `json:"SIGTERM"`
	SigHup   execline.Argv `json:"SIGHUP"`
	SigQuit  execline.Argv `json:"SIGQUIT"`
	SigInt   execline.Argv `json:"SIGINT"`
	SigUsr1  execline.Argv `json:"SIGUSR1"`
	SigUsr2  execline.Argv `json:"SIGUSR2"`
	SigPwr   execline.Argv `json:"SIGPWR"`
	SigWinch execline.Argv `json:"SIGWINCH"`
	Crash    execline.Argv `json:"crash"`
	Finish   execline.Argv `json:"finish"`
}

func (*SvscanScripts) WriteDir

func (sigs *SvscanScripts) WriteDir(cwd int) error

Jump to

Keyboard shortcuts

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