[autoscaler] AWS Autoscaler support for EC2 security group rule configuration#7873
[autoscaler] AWS Autoscaler support for EC2 security group rule configuration#7873pdames wants to merge 4 commits intoray-project:masterfrom
Conversation
|
Can one of the admins verify this patch? |
|
Test FAILed. |
207a0aa to
d0172ee
Compare
|
Test PASSed. |
ci/travis/install-dependencies.sh
Outdated
There was a problem hiding this comment.
I see, it's for boto tests later. These tests don't actually require creds right?
There was a problem hiding this comment.
Correct - the tests are stubbed/mocked out and don't interact with any real AWS account.
|
hey @allenyin55, do you mind reviewing this PR? |
d0172ee to
57688b0
Compare
|
Test FAILed. |
Might be tough this week, but I'll try to make some time for this. |
… inbound rule configuration and separate head/worker subnets.
…ult SSH inbound rules, and correct misleading AWS autoscaler example and test comments.
…ir method signature.
…ules, revoke unspecified rules by default, and revised security group config example.
57688b0 to
acc44d1
Compare
|
FYI, the latest update of this pull request includes changes to deduplicate equivalent, but unequal, rules as mentioned in #7844. Essentially, the rules boil down to simply resolving case-sensitivity differences between prefix and group list IDs, as well as canonicalizing IPv4 and IPv6 addresses. The canonicalization rules rely on fairly standard Java IP address libraries together with a few custom extensions that ultimately produce the same canonical string representations that we can get using https://docs.python.org/3/library/ipaddress.html:
|
|
This PR is just exploding; can you split some of this up into separate PRs? |
|
Test PASSed. |
I'm open to whatever makes your job easiest. There are a few ways that I could see us split it up going forward:
Let me know if you have a preference (or if the preference perhaps isn't listed here). |
Why are these changes needed?
In general, I believe that we should decouple AWS autoscaler users from these responsibilities by allowing them to specify common security group configuration overrides to apply during default security group bootstrapping. To that end, these changes expose new AWS autoscaler configuration settings that allow users to specify custom inbound head/worker node security group rules to apply (via authorization of new rules or revocation of old rules) during config bootstrapping. Please refer to the included "example-security-groups.yaml" file for additional details. Also note that, if no custom security group rule config is specified, then prior default security group bootstrap behavior is maintained, namely:
It also may be worth noting that additional tests and documentation updates are expected to follow this pull request, but I wanted to collect early reviewer opinions now instead of opening a more complete (but monolithic) pull request later.
Related issue number
#8420
Checks
scripts/format.shto lint the changes in this PR.