amazonka-ecr-1.4.0: Amazon EC2 Container Registry SDK.

Copyright(c) 2013-2016 Brendan Hay
LicenseMozilla Public License, v. 2.0.
MaintainerBrendan Hay <brendan.g.hay@gmail.com>
Stabilityauto-generated
Portabilitynon-portable (GHC extensions)
Safe HaskellNone
LanguageHaskell2010

Network.AWS.ECR.GetAuthorizationToken

Contents

Description

Retrieves a token that is valid for a specified registry for 12 hours. This command allows you to use the docker CLI to push and pull images with Amazon ECR. If you do not specify a registry, the default registry is assumed.

The authorizationToken returned for each registry specified is a base64 encoded string that can be decoded and used in a 'docker login' command to authenticate to a registry. The AWS CLI offers an 'aws ecr get-login' command that simplifies the login process.

Synopsis

Creating a Request

getAuthorizationToken :: GetAuthorizationToken Source

Creates a value of GetAuthorizationToken with the minimum fields required to make a request.

Use one of the following lenses to modify other fields as desired:

Request Lenses

gatRegistryIds :: Lens' GetAuthorizationToken (Maybe (NonEmpty Text)) Source

A list of AWS account IDs that are associated with the registries for which to get authorization tokens. If you do not specify a registry, the default registry is assumed.

Destructuring the Response

getAuthorizationTokenResponse Source

Creates a value of GetAuthorizationTokenResponse with the minimum fields required to make a request.

Use one of the following lenses to modify other fields as desired:

Response Lenses

gatrsAuthorizationData :: Lens' GetAuthorizationTokenResponse [AuthorizationData] Source

A list of authorization token data objects that correspond to the registryIds values in the request.