Documentation
¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type LocalManager ¶
type LocalManager struct {
// contains filtered or unexported fields
}
A LocalManager manages services with a custom service runner
func NewLocalManager ¶
func NewLocalManager(stateFile string) *LocalManager
NewLocalManager creates a new local manager
func (*LocalManager) Install ¶
func (lsm *LocalManager) Install(service Service) error
Install installs the service
func (*LocalManager) List ¶
func (lsm *LocalManager) List() ([]string, error)
List lists the installed services
func (*LocalManager) String ¶
func (lsm *LocalManager) String() string
func (*LocalManager) Uninstall ¶
func (lsm *LocalManager) Uninstall(name string) error
Uninstall uninstalls the service
type Manager ¶
type Manager interface {
Install(service Service) error
Uninstall(serviceName string) error
List() ([]string, error)
}
A Manager manages services
type SystemDManager ¶
type SystemDManager struct {
// contains filtered or unexported fields
}
A SystemDManager manages services in systemd
func NewSystemDManager ¶
func NewSystemDManager(unitFilePath string, userMode bool) *SystemDManager
NewSystemDManager creates a new systemd service manager
func (*SystemDManager) Install ¶
func (mgr *SystemDManager) Install(service Service) error
Install installs the service
func (*SystemDManager) List ¶
func (mgr *SystemDManager) List() ([]string, error)
List lists the installed services
func (*SystemDManager) String ¶
func (mgr *SystemDManager) String() string
func (*SystemDManager) Uninstall ¶
func (mgr *SystemDManager) Uninstall(name string) error
Uninstall uninstall a service
type UpstartServiceManager ¶
type UpstartServiceManager struct {
}
func NewUpstartServiceManager ¶
func NewUpstartServiceManager() *UpstartServiceManager
func (*UpstartServiceManager) Install ¶
func (usm *UpstartServiceManager) Install(service Service) error
func (*UpstartServiceManager) List ¶
func (usm *UpstartServiceManager) List() ([]string, error)
func (*UpstartServiceManager) Uninstall ¶
func (usm *UpstartServiceManager) Uninstall(name string) error
Click to show internal directories.
Click to hide internal directories.