-
Notifications
You must be signed in to change notification settings - Fork 1.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
Support regions without m4 machines #1163
Support regions without m4 machines #1163
Conversation
I've pushed https://github.com/wking/openshift-installer.git fixup-bootstrap-default-type (c3d322c) with the code needed to get the bootstrap type from Go through Terraform to its eventual resource consumer. We still need to update the Go to feed in the dynamic default, but with the logic internal to |
pkg/asset/machines/master.go
Outdated
var ( | ||
_ asset.Asset = (*Master)(nil) | ||
|
||
defaultMachineClass = map[string]string{ |
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.
aws specific code should live in pkg/asset/machines/aws
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.
also WDYT using m4 by default and overriding only some regions, so that we only maintain override list?
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.
aws specific code should live in
pkg/asset/machines/aws
This and some other feedback attached to eparis/installer@bc58267. I dunno why @eparis didn't just push that to this PR for feedback ;).
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.
your hope was that I only keep non-m4 regions in this map instead of every region? I can probably do that, and fix CI.
pkg/asset/machines/master_test.go
Outdated
} | ||
return true | ||
} | ||
err := svc.GetProductsPages(input, handlePage) |
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.
our unit tests are going to get rate limited :P
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.
our unit tests are going to get rate limited :P
We shouldn't be running that many installer PRs in CI at once, should we? Are product rate limits especially tight?
Vendor conflict; needs a rebase. |
775a729
to
ebd0559
Compare
pushed my second stab at this |
ebd0559
to
1275b04
Compare
I've picked this up and pushed ebd0559 -> 1275b04 to:
|
1275b04
to
147e63d
Compare
unit:
Looks like our CI user lacks
Do we want to set AWS credentials for unit tests? Or should we skip this test when we don't have credentials? If the latter, is the idea that maintainers would periodically run the test manually? |
147e63d
to
f9a381e
Compare
I've pushed 147e63d -> f9a381e, pushing the test out into a new |
d9a52d5
to
3fb0ff6
Compare
I've pushed f9a381e -> 3fb0ff6, rebasing onto master again, and moving |
the AWS bulk pricing api (instead of being able to filter) does not require creds, though then we can't use the aws library and have to just get the raw url. Probably could decode it into the aws library types, but they aren't actually very helpful... |
"eu-west-1": "Ireland", | ||
"eu-west-2": "London", | ||
"eu-west-3": "Paris", | ||
"sa-east-1": "São Paulo", | ||
"us-east-1": "N. Virginia", | ||
"us-east-2": "Ohio", | ||
"us-gov-east-1": "AWS GovCloud (US-East)", | ||
"us-gov-west-1": "AWS GovCloud (US-West)", |
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.
You sure about this? The pricing API calls this AWS GovCloud (US)
I think...
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.
The pricing API calls this
AWS GovCloud (US)
I think...
It does, but I have an entry for decoding that here. They use US-West
in other places, and now that US-East
exists, I think the qualified name makes more sense here.
I'm fine with a transition here, but am also fine punting that to follow-up work. |
3fb0ff6
to
3745dcf
Compare
From the logs:
I've never seen that one before. |
From Trevor: For regions like eu-west-3 (Paris) that don't support m4. The only instance type available in all AWS regions today is i3. We prefer m4 because of the higher EBS attach limit. But for regions that don't support m4 we use m5. This also adds a CI job which checks the AWS pricing API to keep our region map up to date. The eu-north-1 region is new as of 2018-12-12 [1], and it show up in: $ aws ec2 describe-regions --query 'Regions[].RegionName' --output json | jq -r 'sort[]' ... eu-central-1 eu-north-1 eu-west-1 ... The GovCloud entries didn't show up in that query (maybe they are only listed for accounts that have access?), but they are listed on [2]. The new test is in platformtests/aws to keep it out of our default unit tests. Maintainers can run it manually to verify that the default fallbacks we hard-code are still appropriate for the current AWS offerings. It's not in tests/aws, because 'dep ensure' seems to ignore tests. I think it's fine to have both platformtests and tests in parallel, with the former holding tests who share the project vendor/ and the latter holding tests which have a distinct vendor/. bdd-smoke is in tests with its own vendor/ intentionally to keep gomega and other test-specific libraries out of the project vendor/ [3]. But for these tests we're using Go's built-in test framework, so it's less maintenance to layer our minimal additional dependencies into the project vendor/. [1]: https://aws.amazon.com/blogs/aws/now-open-aws-europe-stockholm-region/ [2]: https://aws.amazon.com/about-aws/global-infrastructure/regional-product-services/ [3]: openshift#552 (comment)
3745dcf
to
354554d
Compare
/retest |
/retest |
/retest |
Same error as before:
/retest |
Sigh Blocked on openshift/origin#22070. |
/retest |
We'll see about that... /retest |
/retest |
I haven't seen this failure before:
It's an issue with CI; not OpenShift. /retest |
/retest |
/test e2e-aws |
1 similar comment
/test e2e-aws |
/retest |
green ci :yay: /lgtm |
[APPROVALNOTIFIER] This PR is APPROVED This pull-request has been approved by: abhinavdahiya, crawford, eparis The full list of commands accepted by this bot can be found here. The pull request process is described here
Needs approval from an approver in each of these files:
Approvers can indicate their approval by writing |
This does not dynamically pick machine types for the bootstrap node. Instead it just uses i3.large. i3 is the only machine type in all regions of AWS. It costs a little extra (about $0.05/hour) but we only run it for like 20 minutes.
Fixes: #1127