Documentation ¶
Index ¶
- func CompressedTarReader(ctx context.Context, r io.ReadSeeker, unpacker []string, sysOS *sys.OS, ...) (*tar.Reader, context.CancelFunc, error)
- func ExtractWithFds(cmd string, args []string, allowedCmds []string, stdin io.ReadCloser, ...) error
- func Unpack(file string, path string, blockBackend bool, sysOS *sys.OS, ...) error
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func CompressedTarReader ¶
func CompressedTarReader(ctx context.Context, r io.ReadSeeker, unpacker []string, sysOS *sys.OS, outputPath string) (*tar.Reader, context.CancelFunc, error)
CompressedTarReader returns a tar reader from the supplied (optionally compressed) tarball stream. The unpacker arguments are those returned by DetectCompressionFile(). The returned cancelFunc should be called when finished with reader to clean up any resources used. This can be done before reading to the end of the tarball if desired.
func ExtractWithFds ¶
func ExtractWithFds(cmd string, args []string, allowedCmds []string, stdin io.ReadCloser, sysOS *sys.OS, output *os.File) error
ExtractWithFds runs extractor process under specifc AppArmor profile. The allowedCmds argument specify commands which are allowed to run by apparmor. The cmd argument is automatically added to allowedCmds slice.
func Unpack ¶
func Unpack(file string, path string, blockBackend bool, sysOS *sys.OS, tracker *ioprogress.ProgressTracker) error
Unpack extracts image from archive.
Types ¶
This section is empty.
Click to show internal directories.
Click to hide internal directories.