dockerutil

package
v0.22.3 Latest Latest
Warning

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

Go to latest
Published: Dec 30, 2025 License: MIT Imports: 5 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func Build

func Build(dockerFilePathOrDir, name, tag string, verbose bool) (string, string, error)

func FindDockerFile

func FindDockerFile() (string, error)

func IsDockerAvailable

func IsDockerAvailable() bool

func IsLoggedIn

func IsLoggedIn(registryUrl string) bool

func Login

func Login(registryUrl, username, password string) error

func Logout

func Logout(registryUrl string) error

func Push

func Push(nameTag, registryUrl string) (string, error)

Types

type DockerInspectResult

type DockerInspectResult struct {
	Id            string   `json:"Id"`
	RepoTags      []string `json:"RepoTags"`
	RepoDigests   []string `json:"RepoDigests"`
	Parent        string   `json:"Parent"`
	Comment       string   `json:"Comment"`
	Created       string   `json:"Created"`
	DockerVersion string   `json:"DockerVersion"`
	Author        string   `json:"Author"`
	Config        struct {
		Hostname     string                 `json:"Hostname"`
		Domainname   string                 `json:"Domainname"`
		User         string                 `json:"User"`
		AttachStdin  bool                   `json:"AttachStdin"`
		AttachStdout bool                   `json:"AttachStdout"`
		AttachStderr bool                   `json:"AttachStderr"`
		ExposedPorts map[string]interface{} `json:"ExposedPorts"`
		Tty          bool                   `json:"Tty"`
		OpenStdin    bool                   `json:"OpenStdin"`
		StdinOnce    bool                   `json:"StdinOnce"`
		Env          []string               `json:"Env"`
		Cmd          interface{}            `json:"Cmd"`
		Image        string                 `json:"Image"`
		Volumes      interface{}            `json:"Volumes"`
		WorkingDir   string                 `json:"WorkingDir"`
		Entrypoint   []string               `json:"Entrypoint"`
		OnBuild      interface{}            `json:"OnBuild"`
		Labels       interface{}            `json:"Labels"`
	} `json:"Config"`
	Architecture string `json:"Architecture"`
	Os           string `json:"Os"`
	Size         int64  `json:"Size"`
	GraphDriver  struct {
		Data interface{} `json:"Data"`
		Name string      `json:"Name"`
	} `json:"GraphDriver"`
	RootFS struct {
		Type   string   `json:"Type"`
		Layers []string `json:"Layers"`
	} `json:"RootFS"`
	Metadata struct {
		LastTagTime string `json:"LastTagTime"`
	} `json:"Metadata"`
	Descriptor struct {
		MediaType string `json:"mediaType"`
		Digest    string `json:"digest"`
		Size      int64  `json:"size"`
	} `json:"Descriptor"`
}

func Inspect

func Inspect(nameTag string) (DockerInspectResult, error)

Jump to

Keyboard shortcuts

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