svc_runtime

package
v0.6.29 Latest Latest
Warning

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

Go to latest
Published: May 15, 2026 License: Apache-2.0 Imports: 10 Imported by: 0

Documentation

Overview

HealthStatus returns the Docker health check status for a named service. Returns "healthy", "unhealthy", "starting", or "" (no health check / not found).

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func GetSvcMgrName

func GetSvcMgrName() string

Types

type DockerService added in v0.6.5

type DockerService struct{}

func (*DockerService) HealthStatus added in v0.6.22

func (d *DockerService) HealthStatus(name string) (string, error)

func (*DockerService) Ice added in v0.6.22

func (d *DockerService) Ice(name string) error

Ice stops the container and removes its image to free up disk space. The container configuration is preserved in the service store so it can be redeployed.

func (*DockerService) Install added in v0.6.5

func (d *DockerService) Install(name, desc, runCmd, workDir string, envVars map[string]string) error

func (*DockerService) Remove added in v0.6.5

func (d *DockerService) Remove(name string) error

func (*DockerService) Start added in v0.6.5

func (d *DockerService) Start(name string) error

func (*DockerService) Status added in v0.6.5

func (d *DockerService) Status(name string) (string, error)

func (*DockerService) Stop added in v0.6.5

func (d *DockerService) Stop(name string) error

type LaunchdManager

type LaunchdManager struct {
	DockerService
}

func (*LaunchdManager) Install

func (l *LaunchdManager) Install(name, desc, runCmd, workDir string, envVars map[string]string) error

func (*LaunchdManager) Remove

func (l *LaunchdManager) Remove(name string) error

func (*LaunchdManager) Status

func (l *LaunchdManager) Status(name string) (string, error)

type NSSMManager

type NSSMManager struct {
	DockerService
}

func (*NSSMManager) Install

func (n *NSSMManager) Install(name, desc, runCmd, workDir string, envVars map[string]string) error

func (*NSSMManager) Remove

func (n *NSSMManager) Remove(name string) error

func (*NSSMManager) Status

func (n *NSSMManager) Status(name string) (string, error)

type ServiceManager

type ServiceManager interface {
	Status(name string) (string, error)
	HealthStatus(name string) (string, error)
	Install(name, desc, runCmd, workDir string, envVars map[string]string) error
	Start(name string) error
	Stop(name string) error
	Remove(name string) error
	Ice(name string) error
}

ServiceManager defines the interface for service management across platforms

func SvcRuntime

func SvcRuntime() (ServiceManager, error)

type SystemdManager

type SystemdManager struct {
	DockerService
}

func (*SystemdManager) Install

func (s *SystemdManager) Install(name, desc, runCmd, workDir string, envVars map[string]string) error

func (*SystemdManager) Status

func (s *SystemdManager) Status(name string) (string, error)

Jump to

Keyboard shortcuts

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