Documentation ¶
Overview ¶
Package ecr helps generate clients to talk to the ECR API
Index ¶
Constants ¶
const ( MinimumJitterDuration = 30 * time.Minute MaximumJitterDuration = 1 * time.Hour )
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type ECRAuthData ¶ added in v1.18.0
type ECRAuthData struct { EndpointOverride string `json:"endpointOverride"` Region string `json:"region"` RegistryID string `json:"registryId"` UseExecutionRole bool `json:"useExecutionRole"` // contains filtered or unexported fields }
ECRAuthData is the authentication details for ECR specifying the region, registryID, and possible endpoint override
func (*ECRAuthData) GetPullCredentials ¶ added in v1.18.0
func (auth *ECRAuthData) GetPullCredentials() credentials.IAMRoleCredentials
GetPullCredentials returns the pull credentials in the auth
func (*ECRAuthData) SetPullCredentials ¶ added in v1.18.0
func (auth *ECRAuthData) SetPullCredentials(creds credentials.IAMRoleCredentials)
SetPullCredentials sets the credentials to pull from ECR in the auth
type ECRClient ¶ added in v1.13.0
type ECRClient interface {
GetAuthorizationToken(registryId string) (*ecrapi.AuthorizationData, error)
}
ECRClient wrapper interface for mocking
func NewECRClient ¶ added in v1.13.0
NewECRClient creates an ECR client used to get docker auth from ECR
type ECRFactory ¶
type ECRFactory interface {
GetClient(*ECRAuthData) (ECRClient, error)
}
ECRFactory defines the interface to produce an ECR SDK client
func NewECRFactory ¶
func NewECRFactory(acceptInsecureCert bool) ECRFactory
NewECRFactory returns an ECRFactory capable of producing ECRSDK clients
type ECRSDK ¶
type ECRSDK interface {
GetAuthorizationToken(*ecrapi.GetAuthorizationTokenInput) (*ecrapi.GetAuthorizationTokenOutput, error)
}
ECRSDK is an interface that specifies the subset of the AWS Go SDK's ECR client that the Agent uses. This interface is meant to allow injecting a mock for testing.
type RegistryAuthenticationData ¶ added in v1.18.0
type RegistryAuthenticationData struct { Type string `json:"type"` ECRAuthData *ECRAuthData `json:"ecrAuthData"` }
RegistryAuthenticationData is the authentication data sent by the ECS backend. Currently, the only supported authentication data is for ECR.