Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

chore(ecs): clarify it's possible to use image digest on fromEcrRepository #27115

Merged
merged 2 commits into from
Sep 12, 2023
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
7 changes: 5 additions & 2 deletions packages/@aws-cdk/aws-sagemaker-alpha/lib/container-image.ts
Original file line number Diff line number Diff line change
Expand Up @@ -26,9 +26,12 @@ export interface ContainerImageConfig {
export abstract class ContainerImage {
/**
* Reference an image in an ECR repository
*
* @param repository ECR repository
* @param tagOrDigest Optional image tag or digest (digests must start with `sha256:`)
*/
public static fromEcrRepository(repository: ecr.IRepository, tag: string = 'latest'): ContainerImage {
return new EcrImage(repository, tag);
public static fromEcrRepository(repository: ecr.IRepository, tagOrDigest: string = 'latest'): ContainerImage {
return new EcrImage(repository, tagOrDigest);
}

/**
Expand Down
7 changes: 5 additions & 2 deletions packages/aws-cdk-lib/aws-ecs/lib/container-image.ts
Original file line number Diff line number Diff line change
Expand Up @@ -18,9 +18,12 @@ export abstract class ContainerImage {

/**
* Reference an image in an ECR repository
*
* @param repository ECR repository
* @param tagOrDigest Optional image tag or digest (digests must start with `sha256:`)
*/
public static fromEcrRepository(repository: ecr.IRepository, tag: string = 'latest') {
return new EcrImage(repository, tag);
public static fromEcrRepository(repository: ecr.IRepository, tagOrDigest: string = 'latest') {
return new EcrImage(repository, tagOrDigest);
}

/**
Expand Down