-
Notifications
You must be signed in to change notification settings - Fork 4k
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
[ecr] Lookup function for ECR repositories #8461
Comments
@MrArnoldPalmer created this pr.please let me know if it looks ok. |
Another use case for this is repo replication. If I have an ECR repository in one region, and I want to replicate the images to another region I need to find lookup the source repo in the "main" region. |
The scope of this needs to be wider. There needs to be a standardised way of creating contexts for user-created lookups.. The users want to do ECR lookups, but for me, its other things.. You could solve the specific use-case here, but the other approach would be to provide a method to do arbitory lookups ( using sdk calls, which is what the 'built in lookups' do anyway, and cache them. |
@mrpackethead I agree that would be nice, but I'd settle for solving it on a case-by-case basis over it not being solved at all... This would be a really nice feature but it's still not here after 2½ years. @nohack Sadly it seems the PR died "on the vine" although it looked like it did exactly what was desired. How can we revive it? |
Implement
fromLookup
foraws-ecr
in order to query the repository duringsynth
time.Use Case
Currently when using ECR, if we try to import a repository that doesn't exist using
fromRepositoryArn
,fromRepositoryAttributes
orfromRepositoryName
, it doesn't check if the repository actually exist and sometimes we will only find that out through runtime errors when trying to push to that repo.Using a lookup, we could treat the error during
synth
and therefore, create a repo if it doesn't exist.Proposed Solution
suggested method signature:
example of usage:
Other
Related stackoverflow issue using the CLI https://stackoverflow.com/questions/51028677/create-aws-ecr-repository-if-it-doesnt-exist
This is a 🚀 Feature Request
The text was updated successfully, but these errors were encountered: