-
Story
-
Resolution: Unresolved
-
Normal
-
None
-
None
-
None
-
Product / Portfolio Work
-
False
-
-
False
-
None
-
None
-
CLOUD Sprint 279
User Story
As a GCP administrator, I want to use a provisioningModel: "Spot" field to create worker nodes, so that I can leverage GCP Spot VMs for cost savings instead of the legacy preemptible flag.
Background
GCP now favors provisioningModel: "Spot" over the old preemptible field. This change aligns our API with the modern GCP standard for requesting interruptible instances.Steps
Steps
- Add provisioningModel field to the GCPMachineProviderSpec API.
- Update reconciler logic to set the SPOT provisioning model in the GCP compute API.
- Implement validation (webhook and reconciler) to forbid conflicts between preemptible and provisioningModel.
- Update related logic (restart policy, quotas, labels) for Spot instances.
- Add unit tests for the new API validation and reconciler logic.{}
Definition of Done
- provisioningModel field is added to the v1beta1 API.
- Reconciler creates Spot VMs when provisioningModel: "Spot" is set.
- Validation blocks using both preemptible and provisioningModel: "Spot"
Docs
- OpenShift docs updated to use Spot for interruptible instances. GCP encourages users to uset Spot instead of preemptible. OpenShift should also steer users toward spot over interruptible instances. https://docs.cloud.google.com/compute/docs/instances/preemptible
Testing
- Added unit tests to reconciler_test.go for Spot creation, restart policy, and validation errors.
- Added unit tests to machine_webhook_test.go to validate conflicting and invalid configurations.
- links to