dockerService

package
v0.0.0-...-5746ace Latest Latest
Warning

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

Go to latest
Published: Sep 19, 2023 License: GPL-3.0 Imports: 18 Imported by: 0

Documentation

Index

Constants

View Source
const (
	DockerConnStrRemote = "ssh://%s@%s:22"
)

Variables

View Source
var (
	DockerCtx    context.Context
	DockerClient *client.Client
)

Functions

This section is empty.

Types

type DockerService

type DockerService struct {
}

func NewDockerService

func NewDockerService() *DockerService

func (*DockerService) Connect

func (s *DockerService) Connect()

func (*DockerService) CreateContainer

func (s *DockerService) CreateContainer(name string, cmd []string) (resp container.ContainerCreateCreatedBody, err error)

func (*DockerService) GetContainer

func (s *DockerService) GetContainer(containerId string) (ret types.Container, err error)

func (*DockerService) GetContainerInfo

func (s *DockerService) GetContainerInfo(containerId string) (ret commDomain.ContainerInfo, err error)

func (*DockerService) GetContainerLog

func (s *DockerService) GetContainerLog(containerId string) (ret string, err error)

func (*DockerService) GetImage

func (s *DockerService) GetImage(imageId string) (ret types.ImageSummary, err error)

func (*DockerService) ListContainer

func (s *DockerService) ListContainer() (containers []types.Container, err error)

func (*DockerService) ListImage

func (s *DockerService) ListImage() (images []types.ImageSummary, err error)

func (*DockerService) PullImage

func (s *DockerService) PullImage(refStr string) (err error)

func (*DockerService) RemoveContainer

func (s *DockerService) RemoveContainer(containerId string, removeVolumes, removeLinks, force bool) (err error)

func (*DockerService) StartContainer

func (s *DockerService) StartContainer(containerId string) (err error)

func (*DockerService) StopContainer

func (s *DockerService) StopContainer(containerId string) (err error)

Jump to

Keyboard shortcuts

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