docker

package
v1.0.1 Latest Latest
Warning

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

Go to latest
Published: Aug 15, 2024 License: Apache-2.0 Imports: 19 Imported by: 0 modules, 0 packages

The first number is the count of modules that contain a package that imports this one. The module count is a better indicator of popularity than the package count. A module with 100 importing packages is counted only once instead of 100 times, reflecting the fact that the choice to use the package was likely made only once, not 100 times.
A '?' means that the value hasn't been computed yet.

Documentation

Index

Constants

This section is empty.

Variables

Functions

This section is empty.

Types

type ContainerStatus

type ContainerStatus string
var (
	ContainerStatusRunning    ContainerStatus = "running"
	ContainerStatusRestarting ContainerStatus = "restarting"
	ContainerStatusCreated    ContainerStatus = "created"
	ContainerStatusExited     ContainerStatus = "exited"
	ContainerStatusPaused     ContainerStatus = "paused"
	ContainerStatusRemoving   ContainerStatus = "removing"
	ContainerStatusDead       ContainerStatus = "dead"
)

docker container status

type DockerJob

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

func New

func New(name types.Name) (*DockerJob, error)

TODO: create docker client by executor-enviroment the remote docker client should be created by host, tls-veiry like client.WithHost("tcp://xxx:2375") the local docker client could be created by docker-sock env directly like clinet.FromEnv

func (*DockerJob) BatchDelete

func (d *DockerJob) BatchDelete(ctx context.Context, tasks []*spec.PipelineTask) (data interface{}, err error)

func (*DockerJob) Cancel

func (d *DockerJob) Cancel(ctx context.Context, task *spec.PipelineTask) (data interface{}, err error)

func (*DockerJob) Create

func (d *DockerJob) Create(ctx context.Context, task *spec.PipelineTask) (data interface{}, err error)

func (*DockerJob) Delete

func (d *DockerJob) Delete(ctx context.Context, task *spec.PipelineTask) (data interface{}, err error)

func (*DockerJob) Exist

func (d *DockerJob) Exist(ctx context.Context, task *spec.PipelineTask) (created, started bool, err error)

func (*DockerJob) GenerateDockerVolumes

func (d *DockerJob) GenerateDockerVolumes(job *apistructs.JobFromUser) []mount.Mount

func (*DockerJob) Inspect

func (*DockerJob) Kind

func (d *DockerJob) Kind() types.Kind

func (*DockerJob) Name

func (d *DockerJob) Name() types.Name

func (*DockerJob) Remove

func (d *DockerJob) Remove(ctx context.Context, task *spec.PipelineTask) (data interface{}, err error)

func (*DockerJob) Start

func (d *DockerJob) Start(ctx context.Context, task *spec.PipelineTask) (data interface{}, err error)

func (*DockerJob) Status

func (d *DockerJob) Status(ctx context.Context, task *spec.PipelineTask) (desc apistructs.PipelineStatusDesc, err error)

func (*DockerJob) Update

func (d *DockerJob) Update(ctx context.Context, task *spec.PipelineTask) (interface{}, error)

Jump to

Keyboard shortcuts

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