-
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
fix(ecs): canContainersAccessInstanceRole is ignored when passed in AsgCapacityProvider constructor #20522
fix(ecs): canContainersAccessInstanceRole is ignored when passed in AsgCapacityProvider constructor #20522
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@daschaa thanks for the fix!
I'm wondering if it might also be good to throw an error if the user sets canContainersAccessInstanceRole
on both and they are different values? Like you explicitly set it to true
on one and false
on the other, are you sure?
@corymhall Thanks for the hint! I didn't thought about that case. Another approach/idea is, that |
Co-authored-by: Cory Hall <43035978+corymhall@users.noreply.github.com>
yeah that's a good call. |
@corymhall Cool! I will add a test for that. |
@corymhall I have now added test cases for the precedence. Could you review it again please? |
Thank you for contributing! Your pull request will be updated from master and then merged automatically (do not update manually, and be sure to allow changes to be pushed to your fork). |
AWS CodeBuild CI Report
Powered by github-codebuild-logs, available on the AWS Serverless Application Repository |
Thank you for contributing! Your pull request will be updated from master and then merged automatically (do not update manually, and be sure to allow changes to be pushed to your fork). |
Thank you @daschaa! |
@joeflateau Thank you for creating the issue! Your finding was 99% of the work ❤️ |
Fixes #20293
When adding an AsgCapacityProvider the property
canContainersAccessInstanceRole
is only checked when passed in via the methodaddAsgCapacityProvider
. It is ignored when passing the property via the instantiation of an AsgCapacityProvider. In this PR I added, that if either one way (method or constructor) has got the property set - it is respected in the outcome. For more details please see the issue #20293I decided not to omit the property on the class level because it would bring in breaking changes.
All Submissions:
Adding new Unconventional Dependencies:
New Features
yarn integ
to deploy the infrastructure and generate the snapshot (i.e.yarn integ
without--dry-run
)?By submitting this pull request, I confirm that my contribution is made under the terms of the Apache-2.0 license