Uploaded image for project: 'OpenShift Cloud'
  1. OpenShift Cloud
  2. OCPCLOUD-3173

Implement GCP spot instances support in Machine API

XMLWordPrintable

    • Icon: Story Story
    • Resolution: Unresolved
    • Icon: Normal Normal
    • None
    • None
    • None
    • Product / Portfolio Work
    • False
    • Hide

      None

      Show
      None
    • 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

      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.

              rmanak@redhat.com Radek Manak
              delima@redhat.com Demetrius Lima
              None
              Demetrius Lima, kate barreiros
              None
              None
              Votes:
              0 Vote for this issue
              Watchers:
              3 Start watching this issue

                Created:
                Updated: