Documentation
¶
Overview ¶
Package filetree streams every layer's tar headers (bodies are never read) and diffs the resulting file trees across layers to find wasted bytes: files that a later layer overwrites or deletes (OCI whiteouts), which still ship in the image. It also derives per-layer file counts and the overall efficiency score.
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
Types ¶
type LayerStats ¶
type LayerStats struct {
FileCount int
WastedBytes int64 // bytes in this layer that a later layer shadows or deletes
}
LayerStats is the per-layer output of the analysis.
type Result ¶
type Result struct {
PerLayer []LayerStats
WastedFiles []report.WastedFile
WastedBytes int64
TotalFileBytes int64 // sum of all regular-file bytes across all layers
EfficiencyScore float64
OSRelease map[string]string // parsed /etc/os-release (ID, VERSION_ID, PRETTY_NAME, ...)
}
Result is the full filetree analysis.
Click to show internal directories.
Click to hide internal directories.