Documentation
¶
Index ¶
- Constants
- func CheckSameFile(f1name, f2name string) (bool, error)
- func CheckTar(image string) bool
- func CleanupImage(image Image)
- func GetFileContents(path string) (*string, error)
- func GetFileSystemFromReference(ref types.ImageReference, imgSrc types.ImageSource, path string, ...) error
- func GetImageLayers(pathToImage string) []string
- func GetSize(path string) int64
- func HasFilepathPrefix(path, prefix string) bool
- func HasTag(image string) bool
- func IsTar(path string) bool
- func NewClient() (*client.Client, error)
- func UnTar(r io.Reader, target string, whitelist []string) error
- type CloudPrepper
- type ConfigObject
- type ConfigSchema
- type DaemonPrepper
- func (p *DaemonPrepper) GetConfig() (ConfigSchema, error)
- func (p *DaemonPrepper) GetFileSystem() (string, error)
- func (p *DaemonPrepper) GetHistory() []ImageHistoryItem
- func (p *DaemonPrepper) GetImage() (Image, error)
- func (p *DaemonPrepper) GetSource() string
- func (p *DaemonPrepper) Name() string
- func (p *DaemonPrepper) SetSource(source string)
- type Directory
- type DirectoryEntry
- type Event
- type Image
- type ImageHistoryItem
- type ImageType
- type OriginalPerm
- type Prepper
- type TarPrepper
Constants ¶
View Source
const LatestTag string = ":latest"
Variables ¶
This section is empty.
Functions ¶
func CheckSameFile ¶
func CleanupImage ¶
func CleanupImage(image Image)
func GetFileContents ¶ added in v0.5.1
GetFileContents returns the contents of a file at the specified path
func GetFileSystemFromReference ¶ added in v0.7.0
func GetFileSystemFromReference(ref types.ImageReference, imgSrc types.ImageSource, path string, whitelist []string) error
func GetImageLayers ¶
func HasFilepathPrefix ¶ added in v0.7.0
HasFilepathPrefix checks if the given file path begins with prefix
Types ¶
type CloudPrepper ¶
type CloudPrepper struct {
Source string
Client *client.Client
ImageSource types.ImageSource
}
CloudPrepper prepares images sourced from a Cloud registry
func (*CloudPrepper) GetConfig ¶
func (p *CloudPrepper) GetConfig() (ConfigSchema, error)
func (*CloudPrepper) GetFileSystem ¶
func (p *CloudPrepper) GetFileSystem() (string, error)
func (*CloudPrepper) GetImage ¶
func (p *CloudPrepper) GetImage() (Image, error)
func (*CloudPrepper) GetSource ¶
func (p *CloudPrepper) GetSource() string
func (*CloudPrepper) Name ¶
func (p *CloudPrepper) Name() string
func (*CloudPrepper) SetSource ¶ added in v0.8.0
func (p *CloudPrepper) SetSource(source string)
type ConfigObject ¶
type ConfigObject struct {
Hostname string
Domainname string
User string
AttachStdin bool
AttachStdout bool
AttachStderr bool
ExposedPorts map[string]struct{} `json:"ExposedPorts"`
Tty bool
OpenStdin bool
StdinOnce bool
Env []string `json:"Env"`
Cmd []string `json:"Cmd"`
// Healthcheck *HealthConfig
ArgsEscaped bool `json:",omitempty"`
Image string
Volumes map[string]struct{} `json:"Volumes"`
Workdir string `json:"WorkingDir"`
Entrypoint []string `json:"Entrypoint"`
NetworkDisabled bool `json:",omitempty"`
MacAddress string `json:",omitempty"`
OnBuild []string
Labels map[string]string `json:"Labels"`
StopSignal string `json:",omitempty"`
StopTimeout *int `json:",omitempty"`
Shell []string `json:",omitempty"`
}
func (ConfigObject) AsList ¶ added in v0.9.0
func (c ConfigObject) AsList() []string
type ConfigSchema ¶
type ConfigSchema struct {
Config ConfigObject `json:"config"`
History []ImageHistoryItem `json:"history"`
}
type DaemonPrepper ¶
func (*DaemonPrepper) GetConfig ¶
func (p *DaemonPrepper) GetConfig() (ConfigSchema, error)
func (*DaemonPrepper) GetFileSystem ¶
func (p *DaemonPrepper) GetFileSystem() (string, error)
func (*DaemonPrepper) GetHistory ¶
func (p *DaemonPrepper) GetHistory() []ImageHistoryItem
func (*DaemonPrepper) GetImage ¶
func (p *DaemonPrepper) GetImage() (Image, error)
func (*DaemonPrepper) GetSource ¶
func (p *DaemonPrepper) GetSource() string
func (*DaemonPrepper) Name ¶
func (p *DaemonPrepper) Name() string
func (*DaemonPrepper) SetSource ¶ added in v0.8.0
func (p *DaemonPrepper) SetSource(source string)
type DirectoryEntry ¶
func CreateDirectoryEntries ¶
func CreateDirectoryEntries(root string, entryNames []string) (entries []DirectoryEntry)
func GetDirectoryEntries ¶
func GetDirectoryEntries(d Directory) []DirectoryEntry
type Image ¶
type Image struct {
Source string
FSPath string
Config ConfigSchema
Type ImageType
}
func (*Image) GetRemoteDigest ¶ added in v0.7.0
type ImageHistoryItem ¶
type ImageHistoryItem struct {
CreatedBy string `json:"created_by"`
}
type OriginalPerm ¶ added in v0.9.0
type OriginalPerm struct {
// contains filtered or unexported fields
}
type TarPrepper ¶
func (*TarPrepper) GetConfig ¶
func (p *TarPrepper) GetConfig() (ConfigSchema, error)
func (*TarPrepper) GetFileSystem ¶
func (p *TarPrepper) GetFileSystem() (string, error)
func (*TarPrepper) GetImage ¶
func (p *TarPrepper) GetImage() (Image, error)
func (*TarPrepper) GetSource ¶
func (p *TarPrepper) GetSource() string
func (*TarPrepper) Name ¶
func (p *TarPrepper) Name() string
func (*TarPrepper) SetSource ¶ added in v0.8.0
func (p *TarPrepper) SetSource(source string)
Click to show internal directories.
Click to hide internal directories.