dockerfile

package
v0.0.0-...-65603e6 Latest Latest
Warning

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

Go to latest
Published: Mar 31, 2021 License: Apache-2.0 Imports: 5 Imported by: 0

Documentation

Index

Constants

View Source
const (
	HEALTHCHECK = "healthcheck"
	USER        = "user"
	Root        = "root"
	ADD         = "add"
	Run         = "run"
	FROM        = "from"
	ENV         = "env"
	LABEL       = "label"
)

Variables

This section is empty.

Functions

This section is empty.

Types

type DockerInstruction

type DockerInstruction struct {
	Instruction string
	Flags       []string
	Content     []string
}

DockerInstruction example: - Instruction: run - Flags: --from=builder - Content: apt-get update

func InitDockerInstruction

func InitDockerInstruction() *DockerInstruction

func (*DockerInstruction) String

func (di *DockerInstruction) String() string

type Dockerfile

type Dockerfile struct {
	File         string
	Instructions []*DockerInstruction
}

func NewDockerfile

func NewDockerfile(file string) *Dockerfile

func (*Dockerfile) AddNode

func (df *Dockerfile) AddNode(node *parser.Node)

func (*Dockerfile) GetBaseImages

func (df *Dockerfile) GetBaseImages() []string

func (*Dockerfile) LookupInstruction

func (df *Dockerfile) LookupInstruction(inst string) bool

func (*Dockerfile) LookupInstructionAndContent

func (df *Dockerfile) LookupInstructionAndContent(inst, cont string) []int

func (*Dockerfile) String

func (df *Dockerfile) String() string

Jump to

Keyboard shortcuts

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