Documentation
¶
Overview ¶
Package bundle produces deterministic, distribution-ready installer package tarballs. The output is the input to `installer push` and is what an OCI registry stores as a single layer of a native installer artifact.
Determinism: same source tree → byte-identical .tgz, regardless of mtimes, uids, host platform, or walk order. This is what makes signing and digest-pinning meaningful.
Index ¶
Constants ¶
const IgnoreFile = ".installerignore"
IgnoreFile is the name of the per-package ignore file (gitignore syntax).
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Result ¶
type Result struct {
// Digest is the sha256 of the gzipped tar, hex-encoded (no "sha256:" prefix).
Digest string
// Files is the list of paths included, in tar order.
Files []string
// Size is the size of the .tgz in bytes.
Size int64
}
Result is the outcome of a Bundle call.
func Bundle ¶
Bundle writes a deterministic .tgz of srcDir to dstFile.
Refuses to include:
- any file matching *.env.secret anywhere in the tree
- anything under <srcDir>/out/
- anything matched by <srcDir>/.installerignore (gitignore syntax)
- .git/, .DS_Store (default ignores; not configurable)
dstFile's parent directory is created if needed; the file is replaced if it exists.