docker

package
v0.0.0-...-2f07197 Latest Latest
Warning

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

Go to latest
Published: Apr 24, 2025 License: MIT Imports: 13 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Client

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

Client represents a Docker client

func NewClient

func NewClient() (*Client, error)

NewClient creates a new Docker client

func (*Client) ProcessImageTask

func (c *Client) ProcessImageTask(sourceImage string, targetImage string, archs []string, allArch bool,
	saveLocally bool, options SaveOptions, auth RegistryAuth) error

ProcessImageTask processes a single image task which can include pulling, saving, and pushing

func (*Client) PullAllArchitectures

func (c *Client) PullAllArchitectures(imageName string, options SaveOptions) error

PullAllArchitectures pulls all available architectures for an image

func (*Client) PullSpecificArchitectures

func (c *Client) PullSpecificArchitectures(imageName string, archs []string, options SaveOptions) error

PullSpecificArchitectures pulls specific architectures for an image

func (*Client) PushAllArchitectures

func (c *Client) PushAllArchitectures(sourceImage, targetImage string, auth RegistryAuth, options SaveOptions) error

PushAllArchitectures pulls all architectures from source image and pushes them to target registry

func (*Client) PushSpecificArchitectures

func (c *Client) PushSpecificArchitectures(sourceImage, targetImage string, archs []string, auth RegistryAuth, options SaveOptions) error

PushSpecificArchitectures pulls specific architectures from source image and pushes them to target registry

type Platform

type Platform struct {
	OS           string
	Architecture string
	Variant      string
}

Platform represents an image platform

type PullOptions

type PullOptions struct {
	Platform string
}

PullOptions for docker pull

type PushOptions

type PushOptions struct {
	RegistryAuth string
}

PushOptions for docker push

type RegistryAuth

type RegistryAuth struct {
	Username string
	Password string
	URL      string
	Insecure bool
}

RegistryAuth contains authentication information for a Docker registry

type SaveOptions

type SaveOptions struct {
	UseCompression   bool
	OutputDir        string
	OperatingSystems []string
	CreateMultiArch  bool
}

SaveOptions represents options for saving images

Jump to

Keyboard shortcuts

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