Merge pull request #1383 from stevvooe/document-config-function
images: document config utility function
This commit is contained in:
commit
c890ca9bce
@ -67,6 +67,11 @@ func (image *Image) Size(ctx context.Context, provider content.Provider) (int64,
|
||||
}), ChildrenHandler(provider)), image.Target)
|
||||
}
|
||||
|
||||
// Config resolves the image configuration descriptor using a content provided
|
||||
// to resolve child resources on the image.
|
||||
//
|
||||
// The caller can then use the descriptor to resolve and process the
|
||||
// configuration of the image.
|
||||
func Config(ctx context.Context, provider content.Provider, image ocispec.Descriptor) (ocispec.Descriptor, error) {
|
||||
var configDesc ocispec.Descriptor
|
||||
return configDesc, Walk(ctx, HandlerFunc(func(ctx context.Context, desc ocispec.Descriptor) ([]ocispec.Descriptor, error) {
|
||||
|
Loading…
Reference in New Issue
Block a user