container

package
v0.4.12 Latest Latest
Warning

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

Go to latest
Published: Jun 7, 2023 License: Apache-2.0 Imports: 10 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

View Source
var GetFullURL = func(u string) (string, error) {
	tokens := strings.Split(u, "@")
	if len(tokens) == 0 {
		return "", fmt.Errorf("GetFullURL: Invalid URL (%s)", u)
	}
	tokens = strings.Split(tokens[0], ":")
	if len(tokens) == 0 {
		return "", fmt.Errorf("GetFullURL: Invalid URL (%s)", u)
	}

	digest, err := crane.Digest(u)
	if err != nil {
		return "", errors.Wrap(err, "Getting digest from url failed")
	}

	return fmt.Sprintf("%s@%s", tokens[0], digest), nil
}

GetFullURL gets the fully qualified container repository url

Functions

func VerifyAndGetAttestations

func VerifyAndGetAttestations(ctx context.Context, resourceURI string) ([]oci.Signature, error)

Types

This section is empty.

Jump to

Keyboard shortcuts

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