-
Notifications
You must be signed in to change notification settings - Fork 40
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
OSASINFRA-3133 - OpenStack support #195
Changes from all commits
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -238,3 +238,41 @@ failureDomains: | |
|
||
> Note: The `targetPools` field may not be set on the GCP providerSpec. This field is required for control | ||
plane machines and you should populate this on both the Machine and the ControlPlaneMachineSet resource specs. | ||
|
||
#### Configuring a control plane machine set on OpenStack | ||
|
||
Two fields are supported for now: `availabilityZone` (instance AZ) and `rootVolume.availabilityZone` (root volume AZ). | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Does this need updating for the third field that we added? There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. volume type will be handled separately via #217 |
||
Gather the existing control plane machines and note the value of the zones of each if they exist. | ||
Aside from these fields, the remaining in spec the machines should be identical. | ||
|
||
Copy the value from one of the machines into the `providerSpec.value` (6) on the example above. | ||
Remove the AZ fields from the `providerSpec.value` once you have done that. | ||
|
||
For each AZ you have in the cluster, configure a failure domain like below: | ||
```yaml | ||
- availabilityZone: "<nova availability zone>" | ||
rootVolume: | ||
availabilityZone: "<cinder availability zone>" | ||
``` | ||
|
||
With these zones, the complete `failureDomains` (4 and 5) on the example above should look something like below: | ||
```yaml | ||
failureDomains: | ||
platform: OpenStack | ||
openstack: | ||
- availabilityZone: nova-az0 | ||
rootVolume: | ||
availabilityZone: cinder-az0 | ||
- availabilityZone: nova-az1 | ||
rootVolume: | ||
availabilityZone: cinder-az1 | ||
- availabilityZone: nova-az2 | ||
rootVolume: | ||
availabilityZone: cinder-az2 | ||
``` | ||
|
||
Prior to 4.14, if the masters were configured with Availability Zones (AZ), the installer (via Terraform) would create | ||
one ServerGroup in OpenStack (the one initially created for master-0, ending with the name of the AZ) but configure | ||
the Machine ProviderSpec with different ServerGroups, one per AZ. | ||
So if you upgrade a cluster from a previous release to 4.14, you'll need to follow this [solution](https://access.redhat.com/solutions/7013893). | ||
|
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -93,7 +93,7 @@ func buildControlPlaneMachineSetAWSMachineSpec(logger logr.Logger, machines []ma | |
} | ||
|
||
// buildAWSFailureDomains builds an AWS flavored FailureDomains for the ControlPlaneMachineSet. | ||
func buildAWSFailureDomains(failureDomains *failuredomain.Set) machinev1.FailureDomains { | ||
func buildAWSFailureDomains(failureDomains *failuredomain.Set) (machinev1.FailureDomains, error) { //nolint:unparam | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. note for reviewers: in a comment with Damiano, we want consistent buildFD functions for the providers, so since OpenStack can return an actual error, we let all builders to return an error too (even if the error is nil for now). |
||
awsFailureDomains := []machinev1.AWSFailureDomain{} | ||
|
||
for _, fd := range failureDomains.List() { | ||
|
@@ -105,5 +105,5 @@ func buildAWSFailureDomains(failureDomains *failuredomain.Set) machinev1.Failure | |
Platform: configv1.AWSPlatformType, | ||
} | ||
|
||
return cpmsFailureDomain | ||
return cpmsFailureDomain, nil | ||
} |
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.
Didn't we add another field to the AZ?
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.
if you're talking about the volume type, it'll be handled separately via #217