dockercmd

package
v1.1.1 Latest Latest
Warning

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

Go to latest
Published: Jun 14, 2024 License: MIT Imports: 12 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type DockerClient

type DockerClient struct {
	// contains filtered or unexported fields
}

func NewDockerClient

func NewDockerClient() DockerClient

func (*DockerClient) DeleteContainer

func (dc *DockerClient) DeleteContainer(id string, opts container.RemoveOptions) error

Deletes the container

func (*DockerClient) DeleteImage

func (dc *DockerClient) DeleteImage(id string, opts image.RemoveOptions) error

func (DockerClient) DeleteVolume

func (dc DockerClient) DeleteVolume(id string, force bool) error

func (*DockerClient) GetContainerLogs

func (dc *DockerClient) GetContainerLogs(id string) (io.ReadCloser, error)

gets logs

func (*DockerClient) InspectContainer

func (dc *DockerClient) InspectContainer(id string) (*types.ContainerJSON, error)

func (*DockerClient) ListContainers

func (dc *DockerClient) ListContainers(showContainerSize bool) []types.Container

func (*DockerClient) ListImages

func (dc *DockerClient) ListImages() []image.Summary

func (DockerClient) ListVolumes

func (dc DockerClient) ListVolumes() ([]*volume.Volume, error)

func (DockerClient) PingDocker

func (dc DockerClient) PingDocker() error

func (*DockerClient) PruneContainers

func (dc *DockerClient) PruneContainers() (types.ContainersPruneReport, error)

func (*DockerClient) PruneImages

func (dc *DockerClient) PruneImages() (types.ImagesPruneReport, error)

func (DockerClient) PruneVolumes

func (dc DockerClient) PruneVolumes() (*types.VolumesPruneReport, error)

func (*DockerClient) RestartContainer

func (dc *DockerClient) RestartContainer(id string) error

func (*DockerClient) ScoutImage

func (dc *DockerClient) ScoutImage(imageName string) (*ScoutData, error)

runs docker scout and parses the output using regex

func (*DockerClient) ToggleContainerListAll

func (dc *DockerClient) ToggleContainerListAll()

Toggles listing of inactive containers

func (*DockerClient) TogglePauseResume

func (dc *DockerClient) TogglePauseResume(id string) error

func (*DockerClient) ToggleStartStopContainer

func (dc *DockerClient) ToggleStartStopContainer(id string) error

Toggles running state of container

type ImageVulnerabilities

type ImageVulnerabilities struct {
	Label           string
	ImageName       string
	Critical        string
	High            string
	Medium          string
	Low             string
	UnknownSeverity string
}

type ScoutData

type ScoutData struct {
	ImageVulEntries []ImageVulnerabilities
}

Jump to

Keyboard shortcuts

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