service

package
v0.0.0-...-d1bef24 Latest Latest
Warning

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

Go to latest
Published: Feb 17, 2026 License: GPL-3.0 Imports: 7 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Service

type Service struct {
	Name        string
	Description string
	Command     string
	Args        []string
	After       []string // Services this depends on
	Type        string   // "oneshot" or "daemon"
	Restart     string   // "always", "on-failure", "never"
	Environment map[string]string
	TTY         string // TTY device path (e.g., "/dev/tty1"), empty for init's stdio

	// Runtime state
	Process *os.Process
	Started bool
	Failed  bool
	Retries int // Number of consecutive restart attempts after failure
}

Service represents a service configuration.

func Parse

func Parse(path string) (*Service, error)

func (*Service) Start

func (s *Service) Start() error

Jump to

Keyboard shortcuts

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