WithUsageManifestLimit sets the limit to the number of manifests which will be walked for usage. Setting this value to 0 will require all manifests to be walked, returning ErrNotFound if manifests are missing. NOTE: By default all manifests which exist will be walked and any non-existent manifests a
(i int)
| 84 | // NOTE: By default all manifests which exist will be walked |
| 85 | // and any non-existent manifests and their subobjects will be ignored. |
| 86 | func WithUsageManifestLimit(i int) UsageOpt { |
| 87 | // If 0 then don't filter any manifests |
| 88 | // By default limits to current platform |
| 89 | return func(o *usageOptions) error { |
| 90 | o.manifestLimit = &i |
| 91 | return nil |
| 92 | } |
| 93 | } |
| 94 | |
| 95 | // WithSnapshotUsage will check for referenced snapshots from the image objects |
| 96 | // and include the snapshot size in the total usage. |
no outgoing calls
searching dependent graphs…