Bruno Casarotti
Bruno Casarotti

Reputation: 643

Can I select a container image from private ECR repository in my CloudFormation template?

Hi I was wondering if it would be possible to select a docker imagem from my private respository in ECR using cloud formation yml for later use when configuring my task definition on an ECS service, something like this:

  ContainerImage:
    Description: "Container image"
    Type: AWS::ECR::PrivateRepository

Upvotes: 0

Views: 661

Answers (1)

Marcin
Marcin

Reputation: 238687

The only way to do it is by development of a custom resource. The resource would be a lambda function which would use AWS SDK, such as boto3, to query your ECR, and return a list of available images to your stack for further use.

Upvotes: 1

Related Questions