Repository navigation
Add rootDiskAvailabilityZone to MachineClass - #418
gardener-prow[bot] merged 1 commit into
Conversation
|
Welcome @rhizoet! |
|
The PR needs to be labeled with ok-to-test by a maintainer to trigger the automated validation of the change |
aaronfern
left a comment
There was a problem hiding this comment.
Thanks for the PR @rhizoet!
The generated code was adapted by hand.
Why was this done? make generate would normally generate all files properly. In fact, now that I ran make generate, it did make further changes. Could you do this instead of adapting this code by hand?
Not yet tested against a cloud with differing compute and Cinder zones.
I assume it's because the openstack installation you have does not contain differing zones (Please correct me if I'm wrong). If that is the case then what is the purpose of this PR? is it for expected changes that will come up, or is it for theoretical completion?
Compute and Cinder availability zones can differ (e.g. compute zone AZ1, Cinder zone nova). Creating the root volume with the machine's zone then fails with 'Availability zone is invalid'. Add an optional rootDiskAvailabilityZone: unset keeps the machine zone, an empty value lets Cinder pick its default zone, any other value selects that zone. It is only evaluated if rootDiskType is set, so validation rejects it without rootDiskType. Signed-off-by: Marius Wernicke <wernicke@23technologies.cloud>
39b92fa to
4c06a4f
Compare
|
The PR needs to be labeled with ok-to-test by a maintainer to trigger the automated validation of the change |
Thanks for the review @aaronfern! Generated code: That was my mistake. I was new to the repo's tooling and didn't realise Validation: Good point, thanks. I added a check in Purpose of the PR: This is not theoretical. A customer has a compute zone ( Testing: I don't have an environment with differing compute and Cinder zones, so this is covered by unit tests only and has not been verified end to end. The change is small and backwards compatible, so I'd like to get it merged and validated once it is available in a release. |
|
Alright, thank you for the explanation. The changes look fine now. |
|
LGTM label has been added. DetailsGit tree hash: 984ca63bce92b24db57ca744afc28daf57203fbe |
|
[APPROVALNOTIFIER] This PR is APPROVED This pull-request has been approved by: AndreasBurger The full list of commands accepted by this bot can be found here. The pull request process is described here DetailsNeeds approval from an approver in each of these files:
Approvers can indicate their approval by writing |
How to categorize this PR?
/area storage
/kind enhancement
/platform openstack
What this PR does / why we need it:
Adds an optional
rootDiskAvailabilityZonefield to theMachineClassprovider spec.If
rootDiskTypeis set, the machine-controller-manager creates the root volume in Cinder itself and passes the availability zone of the machine (spec.availabilityZone) to Cinder. On clouds where the compute and Cinder availability zones are named differently (e.g. compute zoneAZ1, Cinder zonenova, common for SCS clouds), Cinder rejects this withAvailability zone 'AZ1' is invalid.The new field controls the zone used for the root volume:
default_availability_zone, falling back tostorage_availability_zone)Without a
rootDiskType, Nova creates the volume itself, so nothing changes there.Which issue(s) this PR fixes:
Part of gardener/gardener-extension-provider-openstack#1229
Special notes for your reviewer:
The extension counterpart (
CloudProfileConfig.rootDiskAvailabilityZone) follows once this is released.Not yet tested against a cloud with differing compute and Cinder zones. Unit tests cover the zone selection.
The generated code was adapted by hand.
Release note: