pkgmeta

package
v0.1.18 Latest Latest
Warning

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

Go to latest
Published: Aug 26, 2026 License: Apache-2.0, MIT Imports: 13 Imported by: 0

Documentation

Overview

Package pkgmeta reads normalized metadata from native DEB, RPM, and APK package files. DEB and RPM queries run through fixed networkless container invocations; APK control metadata is parsed directly from the package.

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Inspector

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

Inspector reads native package metadata without trusting filenames.

DEB and RPM inspection runs fixed commands in networkless read-only containers. APK inspection parses the concatenated gzip/tar package streams directly and reads only the .PKGINFO control member.

func New

func New(options Options) *Inspector

New constructs an Inspector with stable image defaults.

func (*Inspector) Inspect

func (i *Inspector) Inspect(
	ctx context.Context,
	format pkgrepo.Format,
	packagePath string,
) (pkgrepo.PackageMetadata, error)

Inspect implements pkgrepo.Inspector.

type Options

type Options struct {
	// DockerPath overrides the docker executable. Empty resolves "docker" from PATH.
	DockerPath string
	// DebianImage overrides the pinned Debian inspection image.
	DebianImage string
	// FedoraImage overrides the pinned Fedora inspection image.
	FedoraImage string
	// Environ is the child process environment. Nil inherits the parent.
	Environ []string
	// Stderr receives live container diagnostics. Nil discards them.
	Stderr io.Writer
}

Options configures an Inspector.

Directories

Path Synopsis
Package mocks provides generated package metadata inspection test doubles.
Package mocks provides generated package metadata inspection test doubles.

Jump to

Keyboard shortcuts

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