docker

package
v0.1.0 Latest Latest
Warning

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

Go to latest
Published: Nov 23, 2025 License: MIT Imports: 10 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Manager

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

func NewManager

func NewManager(logger *logrus.Logger) (*Manager, error)

NewManager creates a new Docker manager instance

func (*Manager) CheckDocker

func (m *Manager) CheckDocker(ctx context.Context) error

CheckDocker verifies Docker is running and accessible

func (*Manager) ContainerStatus

func (m *Manager) ContainerStatus(ctx context.Context, name string) (string, error)

ContainerStatus returns the status of a container by name

func (*Manager) CreateContainer

func (m *Manager) CreateContainer(ctx context.Context, name, image string, config *container.Config, hostConfig *container.HostConfig) (string, error)

CreateContainer creates a new container with the specified configuration

func (*Manager) GetContainerLogs

func (m *Manager) GetContainerLogs(ctx context.Context, name string, tail int) (string, error)

GetContainerLogs retrieves the logs for a container

func (*Manager) PullImage

func (m *Manager) PullImage(ctx context.Context, imageRef string) error

PullImage pulls the latest version of a Docker image

func (*Manager) RemoveContainer

func (m *Manager) RemoveContainer(ctx context.Context, name string) error

RemoveContainer removes a container

func (*Manager) RenameContainer

func (m *Manager) RenameContainer(ctx context.Context, oldName, newName string) error

RenameContainer renames a container

func (*Manager) StartContainer

func (m *Manager) StartContainer(ctx context.Context, name string) error

StartContainer starts a container by name

func (*Manager) StopContainer

func (m *Manager) StopContainer(ctx context.Context, name string) error

StopContainer stops a running container

Jump to

Keyboard shortcuts

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