Documentation
¶
Index ¶
- Constants
- func HasErrorCode(err error, code int) bool
- func NewDummyAppConfig() *config.AppConfig
- func NewDummyLog() *logrus.Entry
- func WrapError(err error) error
- type CommandObject
- type ComplexError
- type Container
- func (c *Container) Attach() (*exec.Cmd, error)
- func (c *Container) DetailsLoaded() bool
- func (c *Container) GetLastStats() (*RecordedStats, bool)
- func (c *Container) Inspect() (domain.ContainerDetails, error)
- func (c *Container) Pause() error
- func (c *Container) Remove(options runtime.RemoveContainerOptions) error
- func (c *Container) RenderTop(ctx context.Context) (string, error)
- func (c *Container) Restart() error
- func (c *Container) Start() error
- func (c *Container) Stop() error
- func (c *Container) Top(ctx context.Context) (domain.TopOutput, error)
- func (c *Container) Unpause() error
- type ContainerCommand
- func (c *ContainerCommand) Close() error
- func (c *ContainerCommand) CreateClientStatMonitor(container *Container)
- func (c *ContainerCommand) DockerComposeConfig() string
- func (c *ContainerCommand) DockerComposeConfigForProject(project *Project) string
- func (c *ContainerCommand) EngineName() string
- func (c *ContainerCommand) GenerateKube(names []string) ([]byte, error)
- func (c *ContainerCommand) GetContainers(existingContainers []*Container) ([]*Container, error)
- func (c *ContainerCommand) GetProjectNames(containers []*Container) []string
- func (c *ContainerCommand) GetServices() ([]*Service, error)
- func (c *ContainerCommand) GetServicesFromContainers(containers []*Container) []*Service
- func (c *ContainerCommand) IsProjectScoped() bool
- func (c *ContainerCommand) NewCommandObject(obj CommandObject) CommandObject
- func (c *ContainerCommand) PodsSupported() bool
- func (c *ContainerCommand) PruneContainers() error
- func (c *ContainerCommand) PruneImages() error
- func (c *ContainerCommand) PruneNetworks() error
- func (c *ContainerCommand) PrunePods() error
- func (c *ContainerCommand) PruneVolumes() error
- func (c *ContainerCommand) QuadletsSupported() bool
- func (c *ContainerCommand) RefreshContainerDetails(containers []*Container) error
- func (c *ContainerCommand) RefreshContainersAndServices(currentContainers []*Container) ([]*Container, []*Service, error)
- func (c *ContainerCommand) RefreshImages() ([]*Image, error)
- func (c *ContainerCommand) RefreshNetworks() ([]*Network, error)
- func (c *ContainerCommand) RefreshPods() ([]*Pod, error)
- func (c *ContainerCommand) RefreshQuadlets() ([]*Quadlet, error)
- func (c *ContainerCommand) RefreshVolumes() ([]*Volume, error)
- func (c *ContainerCommand) SetContainerDetails(containers []*Container)
- func (c *ContainerCommand) ViewAllLogs(project *Project) (*exec.Cmd, error)
- type ContainerStats
- type DerivedStats
- type Image
- type LimitedContainerCommand
- type Network
- type OSCommand
- func (c *OSCommand) AppendLineToFile(filename, line string) error
- func (c *OSCommand) CreateTempFile(filename, content string) (string, error)
- func (c *OSCommand) EditFile(filename string) (*exec.Cmd, error)
- func (c *OSCommand) ExecutableFromString(commandStr string) *exec.Cmd
- func (c *OSCommand) ExecutableFromStringContext(ctx context.Context, commandStr string) *exec.Cmd
- func (c *OSCommand) FileExists(path string) (bool, error)
- func (c *OSCommand) FileType(path string) string
- func (c *OSCommand) Kill(cmd *exec.Cmd) error
- func (c *OSCommand) NewCmd(cmdName string, commandArgs ...string) *exec.Cmd
- func (c *OSCommand) NewCommandStringWithShell(commandStr string) string
- func (c *OSCommand) OpenFile(filename string) error
- func (c *OSCommand) OpenLink(link string) error
- func (c *OSCommand) PipeCommands(commandStrings ...string) error
- func (c *OSCommand) PrepareForChildren(cmd *exec.Cmd)
- func (c *OSCommand) Quote(message string) string
- func (c *OSCommand) Remove(filename string) error
- func (c *OSCommand) RunCommand(command string) error
- func (c *OSCommand) RunCommandWithOutput(command string) (string, error)
- func (c *OSCommand) RunCommandWithOutputContext(ctx context.Context, command string) (string, error)
- func (c *OSCommand) RunCustomCommand(command string) *exec.Cmd
- func (c *OSCommand) RunExecutable(cmd *exec.Cmd) error
- func (c *OSCommand) RunExecutableWithOutput(cmd *exec.Cmd) (string, error)
- func (c *OSCommand) RunPreparedCommand(cmd *exec.Cmd) error
- func (c *OSCommand) SetCommand(cmd func(string, ...string) *exec.Cmd)
- func (c *OSCommand) Unquote(message string) string
- type Platform
- type Pod
- type Project
- type Quadlet
- type RecordedStats
- type Service
- func (s *Service) Attach() (*exec.Cmd, error)
- func (s *Service) Remove(options runtime.RemoveContainerOptions) error
- func (s *Service) RenderTop(ctx context.Context) (string, error)
- func (s *Service) Restart() error
- func (s *Service) Start() error
- func (s *Service) Stop() error
- func (s *Service) Up() error
- func (s *Service) ViewLogs() (*exec.Cmd, error)
- type Volume
Constants ¶
const ( // MustStopContainer tells us that we must stop the container before removing it MustStopContainer = iota )
Variables ¶
This section is empty.
Functions ¶
func NewDummyAppConfig ¶
NewDummyAppConfig creates a new dummy AppConfig for testing
Types ¶
type CommandObject ¶
type CommandObject struct {
DockerCompose string
Service *Service
Container *Container
Image *Image
Volume *Volume
Network *Network
Project *Project
}
CommandObject is what we pass to our template resolvers when we are running a custom command. We do not guarantee that all fields will be populated: just the ones that make sense for the current context
type ComplexError ¶
ComplexError an error which carries a code so that calling code has an easier job to do adapted from https://medium.com/yakka/better-go-error-handling-with-xerrors-1987650e0c79
func (ComplexError) Error ¶
func (ce ComplexError) Error() string
func (ComplexError) Format ¶
func (ce ComplexError) Format(f fmt.State, c rune)
Format is a function
func (ComplexError) FormatError ¶
func (ce ComplexError) FormatError(p xerrors.Printer) error
FormatError is a function
type Container ¶
type Container struct {
Name string
ServiceName string
ContainerNumber string // might make this an int in the future if need be
// OneOff tells us if the container is just a job container or is actually
// bound to the service.
OneOff bool
ProjectName string
ID string
Container domain.ContainerInfo
OSCommand *OSCommand
Log *logrus.Entry
StatHistory []*RecordedStats
Details domain.ContainerDetails
// DetailsFetched is true once Inspect has populated Details at least
// once. Replaces the upstream ContainerJSONBase != nil heuristic.
DetailsFetched bool
MonitoringStats bool
ContainerCommand LimitedContainerCommand
Runtime runtime.ContainerRuntime
Tr *i18n.TranslationSet
StatsMutex deadlock.Mutex
}
Container is one container managed by lazypodman.
func (*Container) Attach ¶
Attach attaches to the container by spawning a `docker attach` process. Phase 1d keeps the interactive attach as a CLI exec, see ADR 0004.
func (*Container) DetailsLoaded ¶
DetailsLoaded reports whether Inspect has populated Details at least once. Sometimes it takes a moment for a freshly-started container to have its details available.
func (*Container) GetLastStats ¶
func (c *Container) GetLastStats() (*RecordedStats, bool)
func (*Container) Inspect ¶
func (c *Container) Inspect() (domain.ContainerDetails, error)
Inspect returns the details of the container.
func (*Container) Remove ¶
func (c *Container) Remove(options runtime.RemoveContainerOptions) error
Remove removes the container.
type ContainerCommand ¶
type ContainerCommand struct {
Log *logrus.Entry
OSCommand *OSCommand
Tr *i18n.TranslationSet
Config *config.AppConfig
// Backend is the resolved container backend ("podman" | "docker"), used
// for backend-aware user-facing messages. See EngineName.
Backend string
// Runtime is the sole abstraction lazypodman uses to talk to the
// container engine. See docs/adr/0004-phase-1d-staged-rewire-strategy.md.
Runtime runtime.ContainerRuntime
InDockerComposeProject bool
// LocalProjectName is the compose project name for the directory where lazypodman was launched.
LocalProjectName string
ErrorChan chan error
ContainerMutex deadlock.Mutex
ServiceMutex deadlock.Mutex
Closers []io.Closer
}
ContainerCommand is our main docker interface
func NewContainerCommand ¶
func NewContainerCommand(log *logrus.Entry, osCommand *OSCommand, tr *i18n.TranslationSet, config *config.AppConfig, errorChan chan error) (*ContainerCommand, error)
NewContainerCommand it runs docker commands
func NewDummyContainerCommand ¶
func NewDummyContainerCommand() *ContainerCommand
NewDummyContainerCommand creates a new dummy ContainerCommand for testing
func NewDummyContainerCommandWithOSCommand ¶
func NewDummyContainerCommandWithOSCommand(osCommand *OSCommand) *ContainerCommand
NewDummyContainerCommandWithOSCommand creates a new dummy ContainerCommand for testing
func (*ContainerCommand) Close ¶
func (c *ContainerCommand) Close() error
func (*ContainerCommand) CreateClientStatMonitor ¶
func (c *ContainerCommand) CreateClientStatMonitor(container *Container)
func (*ContainerCommand) DockerComposeConfig ¶
func (c *ContainerCommand) DockerComposeConfig() string
DockerComposeConfig returns the result of 'docker-compose config'
func (*ContainerCommand) DockerComposeConfigForProject ¶
func (c *ContainerCommand) DockerComposeConfigForProject(project *Project) string
DockerComposeConfigForProject returns the result of 'docker-compose config' for a specific project
func (*ContainerCommand) EngineName ¶
func (c *ContainerCommand) EngineName() string
EngineName returns the human-facing name of the active backend ("Podman") for user-facing messages, falling back to a neutral label when the backend is unknown.
func (*ContainerCommand) GenerateKube ¶
func (c *ContainerCommand) GenerateKube(names []string) ([]byte, error)
GenerateKube exports the named pods/containers as Kubernetes YAML. It errors if the active runtime does not implement the KubeGenerator capability (e.g. the Docker backend).
func (*ContainerCommand) GetContainers ¶
func (c *ContainerCommand) GetContainers(existingContainers []*Container) ([]*Container, error)
GetContainers gets the docker containers
func (*ContainerCommand) GetProjectNames ¶
func (c *ContainerCommand) GetProjectNames(containers []*Container) []string
GetProjectNames returns all unique project names from containers
func (*ContainerCommand) GetServices ¶
func (c *ContainerCommand) GetServices() ([]*Service, error)
GetServices gets services
func (*ContainerCommand) GetServicesFromContainers ¶
func (c *ContainerCommand) GetServicesFromContainers(containers []*Container) []*Service
GetServicesFromContainers derives services from container labels for all projects
func (*ContainerCommand) IsProjectScoped ¶
func (c *ContainerCommand) IsProjectScoped() bool
IsProjectScoped reports whether lazypodman should be scoped to a single compose project — either because we're inside a compose directory or because the user passed -p. When false, the project/services panels are hidden and all containers are shown in a flat list.
func (*ContainerCommand) NewCommandObject ¶
func (c *ContainerCommand) NewCommandObject(obj CommandObject) CommandObject
NewCommandObject takes a command object and returns a default command object with the passed command object merged in
func (*ContainerCommand) PodsSupported ¶
func (c *ContainerCommand) PodsSupported() bool
PodsSupported reports whether the active runtime exposes pods.
func (*ContainerCommand) PruneContainers ¶
func (c *ContainerCommand) PruneContainers() error
PruneContainers removes all stopped containers.
func (*ContainerCommand) PruneImages ¶
func (c *ContainerCommand) PruneImages() error
PruneImages removes dangling images.
func (*ContainerCommand) PruneNetworks ¶
func (c *ContainerCommand) PruneNetworks() error
PruneNetworks removes all unused networks.
func (*ContainerCommand) PrunePods ¶
func (c *ContainerCommand) PrunePods() error
PrunePods removes all stopped pods.
func (*ContainerCommand) PruneVolumes ¶
func (c *ContainerCommand) PruneVolumes() error
PruneVolumes removes all unused volumes.
func (*ContainerCommand) QuadletsSupported ¶
func (c *ContainerCommand) QuadletsSupported() bool
QuadletsSupported reports whether the active runtime manages quadlets.
func (*ContainerCommand) RefreshContainerDetails ¶
func (c *ContainerCommand) RefreshContainerDetails(containers []*Container) error
func (*ContainerCommand) RefreshContainersAndServices ¶
func (c *ContainerCommand) RefreshContainersAndServices(currentContainers []*Container) ([]*Container, []*Service, error)
func (*ContainerCommand) RefreshImages ¶
func (c *ContainerCommand) RefreshImages() ([]*Image, error)
RefreshImages returns the current list of images.
func (*ContainerCommand) RefreshNetworks ¶
func (c *ContainerCommand) RefreshNetworks() ([]*Network, error)
RefreshNetworks returns the current list of networks.
func (*ContainerCommand) RefreshPods ¶
func (c *ContainerCommand) RefreshPods() ([]*Pod, error)
RefreshPods returns the current list of pods, or nil when the runtime does not support pods (e.g. the Docker backend).
func (*ContainerCommand) RefreshQuadlets ¶
func (c *ContainerCommand) RefreshQuadlets() ([]*Quadlet, error)
RefreshQuadlets returns the current quadlets, or nil when the runtime does not manage them (e.g. the Docker backend).
func (*ContainerCommand) RefreshVolumes ¶
func (c *ContainerCommand) RefreshVolumes() ([]*Volume, error)
RefreshVolumes returns the current list of volumes.
func (*ContainerCommand) SetContainerDetails ¶
func (c *ContainerCommand) SetContainerDetails(containers []*Container)
Attaches the details returned from docker inspect to each of the containers this contains a bit more info than what you get from the go-docker client
func (*ContainerCommand) ViewAllLogs ¶
func (c *ContainerCommand) ViewAllLogs(project *Project) (*exec.Cmd, error)
ViewAllLogs attaches to a subprocess viewing all the logs from docker-compose
type ContainerStats ¶
type ContainerStats struct {
Read time.Time `json:"read"`
Preread time.Time `json:"preread"`
PidsStats struct {
Current int `json:"current"`
} `json:"pids_stats"`
BlkioStats struct {
IoServiceBytesRecursive []struct {
Major int `json:"major"`
Minor int `json:"minor"`
Op string `json:"op"`
Value int `json:"value"`
} `json:"io_service_bytes_recursive"`
IoServicedRecursive []struct {
Major int `json:"major"`
Minor int `json:"minor"`
Op string `json:"op"`
Value int `json:"value"`
} `json:"io_serviced_recursive"`
IoQueueRecursive []interface{} `json:"io_queue_recursive"`
IoServiceTimeRecursive []interface{} `json:"io_service_time_recursive"`
IoWaitTimeRecursive []interface{} `json:"io_wait_time_recursive"`
IoMergedRecursive []interface{} `json:"io_merged_recursive"`
IoTimeRecursive []interface{} `json:"io_time_recursive"`
SectorsRecursive []interface{} `json:"sectors_recursive"`
} `json:"blkio_stats"`
NumProcs int `json:"num_procs"`
StorageStats struct{} `json:"storage_stats"`
CPUStats struct {
CPUUsage struct {
TotalUsage int64 `json:"total_usage"`
PercpuUsage []int64 `json:"percpu_usage"`
UsageInKernelmode int64 `json:"usage_in_kernelmode"`
UsageInUsermode int64 `json:"usage_in_usermode"`
} `json:"cpu_usage"`
SystemCPUUsage int64 `json:"system_cpu_usage"`
OnlineCpus int `json:"online_cpus"`
ThrottlingData struct {
Periods int `json:"periods"`
ThrottledPeriods int `json:"throttled_periods"`
ThrottledTime int `json:"throttled_time"`
} `json:"throttling_data"`
} `json:"cpu_stats"`
PrecpuStats struct {
CPUUsage struct {
TotalUsage int64 `json:"total_usage"`
PercpuUsage []int64 `json:"percpu_usage"`
UsageInKernelmode int64 `json:"usage_in_kernelmode"`
UsageInUsermode int64 `json:"usage_in_usermode"`
} `json:"cpu_usage"`
SystemCPUUsage int64 `json:"system_cpu_usage"`
OnlineCpus int `json:"online_cpus"`
ThrottlingData struct {
Periods int `json:"periods"`
ThrottledPeriods int `json:"throttled_periods"`
ThrottledTime int `json:"throttled_time"`
} `json:"throttling_data"`
} `json:"precpu_stats"`
MemoryStats struct {
Usage int `json:"usage"`
MaxUsage int `json:"max_usage"`
Stats struct {
ActiveAnon int `json:"active_anon"`
ActiveFile int `json:"active_file"`
Cache int `json:"cache"`
Dirty int `json:"dirty"`
HierarchicalMemoryLimit int64 `json:"hierarchical_memory_limit"`
HierarchicalMemswLimit int64 `json:"hierarchical_memsw_limit"`
InactiveAnon int `json:"inactive_anon"`
InactiveFile int `json:"inactive_file"`
MappedFile int `json:"mapped_file"`
Pgfault int `json:"pgfault"`
Pgmajfault int `json:"pgmajfault"`
Pgpgin int `json:"pgpgin"`
Pgpgout int `json:"pgpgout"`
Rss int `json:"rss"`
RssHuge int `json:"rss_huge"`
TotalActiveAnon int `json:"total_active_anon"`
TotalActiveFile int `json:"total_active_file"`
TotalCache int `json:"total_cache"`
TotalDirty int `json:"total_dirty"`
TotalInactiveAnon int `json:"total_inactive_anon"`
TotalInactiveFile int `json:"total_inactive_file"`
TotalMappedFile int `json:"total_mapped_file"`
TotalPgfault int `json:"total_pgfault"`
TotalPgmajfault int `json:"total_pgmajfault"`
TotalPgpgin int `json:"total_pgpgin"`
TotalPgpgout int `json:"total_pgpgout"`
TotalRss int `json:"total_rss"`
TotalRssHuge int `json:"total_rss_huge"`
TotalUnevictable int `json:"total_unevictable"`
TotalWriteback int `json:"total_writeback"`
Unevictable int `json:"unevictable"`
Writeback int `json:"writeback"`
} `json:"stats"`
Limit int64 `json:"limit"`
} `json:"memory_stats"`
Name string `json:"name"`
ID string `json:"id"`
Networks struct {
Eth0 struct {
RxBytes int `json:"rx_bytes"`
RxPackets int `json:"rx_packets"`
RxErrors int `json:"rx_errors"`
RxDropped int `json:"rx_dropped"`
TxBytes int `json:"tx_bytes"`
TxPackets int `json:"tx_packets"`
TxErrors int `json:"tx_errors"`
TxDropped int `json:"tx_dropped"`
} `json:"eth0"`
} `json:"networks"`
}
ContainerStats autogenerated at https://mholt.github.io/json-to-go/
func (*ContainerStats) CalculateContainerCPUPercentage ¶
func (s *ContainerStats) CalculateContainerCPUPercentage() float64
CalculateContainerCPUPercentage calculates the cpu usage of the container as a percent of total CPU usage to calculate CPU usage, we take the increase in CPU time from the container since the last poll, divide that by the total increase in CPU time since the last poll, times by the number of cores, and times by 100 to get a percentage I'm not entirely sure why we need to multiply by the number of cores, but the numbers work
func (*ContainerStats) CalculateContainerMemoryUsage ¶
func (s *ContainerStats) CalculateContainerMemoryUsage() float64
CalculateContainerMemoryUsage calculates the memory usage of the container as a percent of total available memory
type DerivedStats ¶
DerivedStats contains some useful stats that we've calculated based on the raw container stats that we got back from docker
type Image ¶
type Image struct {
Name string
Tag string
ID string
Image domain.ImageInfo
OSCommand *OSCommand
Log *logrus.Entry
ContainerCommand LimitedContainerCommand
Runtime runtime.ContainerRuntime
}
Image : an OCI image known to the runtime.
func (*Image) Remove ¶
func (i *Image) Remove(options runtime.RemoveImageOptions) error
Remove removes the image.
func (*Image) RenderHistory ¶
RenderHistory renders the image build history as a table.
type LimitedContainerCommand ¶
type LimitedContainerCommand interface {
NewCommandObject(CommandObject) CommandObject
}
LimitedContainerCommand is a stripped-down ContainerCommand with just the methods the container/service/image might need
type Network ¶
type Network struct {
Name string
Network domain.NetworkInfo
OSCommand *OSCommand
Log *logrus.Entry
ContainerCommand LimitedContainerCommand
Runtime runtime.ContainerRuntime
}
Network : a container engine network known to lazypodman.
type OSCommand ¶
type OSCommand struct {
Log *logrus.Entry
Platform *Platform
Config *config.AppConfig
// contains filtered or unexported fields
}
OSCommand holds all the os commands
func NewDummyOSCommand ¶
func NewDummyOSCommand() *OSCommand
NewDummyOSCommand creates a new dummy OSCommand for testing
func NewOSCommand ¶
NewOSCommand os command runner
func (*OSCommand) AppendLineToFile ¶
AppendLineToFile adds a new line in file
func (*OSCommand) CreateTempFile ¶
CreateTempFile writes a string to a new temp file and returns the file's name
func (*OSCommand) EditFile ¶
EditFile opens a file in a subprocess using whatever editor is available, falling back to core.editor, VISUAL, EDITOR, then vi
func (*OSCommand) ExecutableFromString ¶
ExecutableFromString takes a string like `docker ps -a` and returns an executable command for it
func (*OSCommand) ExecutableFromStringContext ¶
Same as ExecutableFromString but cancellable via a context
func (*OSCommand) FileExists ¶
FileExists checks whether a file exists at the specified path
func (*OSCommand) Kill ¶
Kill kills a process. If the process has Setpgid == true, then we have anticipated that it might spawn its own child processes, so we've given it a process group ID (PGID) equal to its process id (PID) and given its child processes will inherit the PGID, we can kill that group, rather than killing the process itself.
func (*OSCommand) NewCommandStringWithShell ¶
func (*OSCommand) PipeCommands ¶
PipeCommands runs a heap of commands and pipes their inputs/outputs together like A | B | C
func (*OSCommand) PrepareForChildren ¶
PrepareForChildren sets Setpgid to true on the cmd, so that when we run it as a subprocess, we can kill its group rather than the process itself. This is because some commands, like `docker-compose logs` spawn multiple children processes, and killing the parent process isn't sufficient for killing those child processes. We set the group id here, and then in subprocess.go we check if the group id is set and if so, we kill the whole group rather than just the one process.
func (*OSCommand) RunCommand ¶
RunCommand runs a command and just returns the error
func (*OSCommand) RunCommandWithOutput ¶
RunCommandWithOutput wrapper around commands returning their output and error
func (*OSCommand) RunCommandWithOutputContext ¶
func (c *OSCommand) RunCommandWithOutputContext(ctx context.Context, command string) (string, error)
RunCommandWithOutput wrapper around commands returning their output and error
func (*OSCommand) RunCustomCommand ¶
RunCustomCommand returns the pointer to a custom command
func (*OSCommand) RunExecutable ¶
RunExecutable runs an executable file and returns an error if there was one
func (*OSCommand) RunExecutableWithOutput ¶
RunExecutableWithOutput runs an executable file and returns its output
func (*OSCommand) RunPreparedCommand ¶
RunPreparedCommand takes a pointer to an exec.Cmd and runs it this is useful if you need to give your command some environment variables before running it
func (*OSCommand) SetCommand ¶
SetCommand sets the command function used by the struct. To be used for testing only
type Platform ¶
type Platform struct {
// contains filtered or unexported fields
}
Platform stores the os state
type Pod ¶
type Pod struct {
Name string
Pod domain.PodInfo
OSCommand *OSCommand
Log *logrus.Entry
ContainerCommand LimitedContainerCommand
Runtime runtime.PodRuntime
}
Pod is a Podman pod. Pods are a Podman-native concept exposed only when the active runtime implements the runtime.PodRuntime capability; on the Docker backend there are none and the GUI hides the panel.
type Quadlet ¶
type Quadlet struct {
Name string
Quadlet domain.Quadlet
OSCommand *OSCommand
Log *logrus.Entry
ContainerCommand LimitedContainerCommand
Runtime runtime.QuadletManager
}
Quadlet is a Podman quadlet (a systemd unit generated from a source file). Quadlets are a Podman-native concept exposed only when the active runtime implements the runtime.QuadletManager capability; on the Docker backend there are none and the GUI hides the panel.
type RecordedStats ¶
type RecordedStats struct {
ClientStats ContainerStats
DerivedStats DerivedStats
RecordedAt time.Time
}
RecordedStats contains both the container stats we've received from docker, and our own derived stats from those container stats. When configuring a graph, you're basically specifying the path of a value in this struct
type Service ¶
type Service struct {
Name string
ID string
ProjectName string
OSCommand *OSCommand
Log *logrus.Entry
Container *Container
ContainerCommand LimitedContainerCommand
}
Service : A docker Service
func (*Service) Remove ¶
func (s *Service) Remove(options runtime.RemoveContainerOptions) error
Remove removes the service's containers
type Volume ¶
type Volume struct {
Name string
Volume domain.VolumeInfo
OSCommand *OSCommand
Log *logrus.Entry
ContainerCommand LimitedContainerCommand
Runtime runtime.ContainerRuntime
}
Volume : a container engine volume known to lazypodman.