Documentation
¶
Overview ¶
Package ecr mints an Amazon ECR registry password from an AWS access key.
ECR has no long-lived registry password: GetAuthorizationToken trades an access key for one that lasts twelve hours. Two places need that — an image app pulling with its own credential (core/oci, issue #41) and the install's image registry adapter pushing builds (adapter/imageregistry/ecr) — so it lives here, in a leaf package core and the adapters can both import, as internal/registrylimit does.
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
Types ¶
type Host ¶ added in v0.10.0
type Host struct {
Region string
// DualStack is a host on ECR's dual-stack (IPv4 and IPv6) endpoint, so
// the password is asked of the API's dual-stack endpoint too: an install
// that reaches the registry only over IPv6 reaches nothing else.
DualStack bool
// FIPS is a host on a FIPS endpoint, so the API's FIPS endpoint is used.
FIPS bool
}
Host is what an ECR registry host says about where to ask for a password.
type Key ¶
type Key struct {
AccessKeyID string
SecretAccessKey secret.Value
Region string
// DualStack and FIPS choose the API endpoint, as the registry host does
// (Parse).
DualStack bool
FIPS bool
// Endpoint overrides the ECR API endpoint, for tests.
Endpoint string
}
Key is an AWS access key, and where to ask.
Click to show internal directories.
Click to hide internal directories.