ecr

package
v0.7.0 Latest Latest
Warning

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

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

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type AccessKeyCredentialHelper

type AccessKeyCredentialHelper interface {
	// GetUsernameAndPassword extracts username and password (a token that lives
	// for 12 hours) from a Secret IF the Secret contains an AWS region, access
	// key id, and secret access key. If the Secret does not contain ANY of these
	// fields, this function will return empty strings and a nil error. If the
	// Secret contains some but not all of these fields, this function will return
	// an error. Implementations may cache the token for efficiency.
	GetUsernameAndPassword(context.Context, *corev1.Secret) (string, string, error)
}

AccessKeyCredentialHelper is an interface for components that can extract a username and password from a Secret containing an AWS region, access key id, and secret access key.

func NewAccessKeyCredentialHelper

func NewAccessKeyCredentialHelper() AccessKeyCredentialHelper

NewAccessKeyCredentialHelper returns an implementation of the AccessKeyCredentialHelper interface that utilizes a cache to avoid unnecessary calls to AWS.

type PodIdentityCredentialHelper

type PodIdentityCredentialHelper interface {
	GetUsernameAndPassword(
		ctx context.Context,
		repoURL string,
		project string,
	) (string, string, error)
}

PodIdentityCredentialHelper is an interface for components that can obtain a username and password for ECR using EKS Pod Identity.

func NewPodIdentityCredentialHelper

func NewPodIdentityCredentialHelper(ctx context.Context) PodIdentityCredentialHelper

NewPodIdentityCredentialHelper returns an implementation of the PodIdentityCredentialHelper interface that utilizes a cache to avoid unnecessary calls to AWS.

Jump to

Keyboard shortcuts

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