paws.compute (version 0.1.0)

ecr_get_authorization_token: Retrieves a token that is valid for a specified registry for 12 hours

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.

Usage

ecr_get_authorization_token(registryIds)

Arguments

registryIds

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.

Request syntax

svc$get_authorization_token(
  registryIds = list(
    "string"
  )
)

Details

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.

Examples

Run this code
# NOT RUN {
# This example gets an authorization token for your default registry.
# }
# NOT RUN {
svc$get_authorization_token()
# }
# NOT RUN {
# }

Run the code above in your browser using DataCamp Workspace