archive

package
v4.0.0-alpha.0+incompa... Latest Latest
Warning

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

Go to latest
Published: Sep 13, 2018 License: Apache-2.0 Imports: 16 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func ApplyLayer

func ApplyLayer(dest string, layer io.Reader, options *TarOptions) (int64, error)

ApplyLayer is copied from github.com/docker/docker/pkg/archive

Types

type AlterHeader

type AlterHeader interface {
	Alter(*tar.Header) (bool, error)
}

type Compression

type Compression int

Compression is the state represents if compressed or not.

type RemapIDs

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

func (RemapIDs) Alter

func (r RemapIDs) Alter(hdr *tar.Header) (bool, error)

type TarOptions

type TarOptions struct {
	IncludeFiles    []string
	ExcludePatterns []string
	Compression     Compression
	NoLchown        bool
	// REMOVED: use remap instead
	//UIDMaps          []idtools.IDMap
	//GIDMaps          []idtools.IDMap
	ChownOpts        *idtools.IDPair
	IncludeSourceDir bool
	// WhiteoutFormat is the expected on disk format for whiteout files.
	// This format will be converted to the standard format on pack
	// and from the standard format on unpack.
	WhiteoutFormat WhiteoutFormat
	// When unpacking, specifies whether overwriting a directory with a
	// non-directory is allowed and vice versa.
	NoOverwriteDirNonDir bool
	// For each include when creating an archive, the included name will be
	// replaced with the matching name from this map.
	RebaseNames map[string]string
	InUserNS    bool

	// ADDED: allow bypassing chown
	// If false, no chown will be performed
	Chown bool

	AlterHeaders AlterHeader
}

TarOptions wraps the tar options.

type WhiteoutFormat

type WhiteoutFormat int

WhiteoutFormat is the format of whiteouts unpacked

Jump to

Keyboard shortcuts

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