0

I'm working on an in-house implementation of a Google Cloud deployment for a Docksal sandbox VM instance. The sandboxes contained within can be considered ephemeral and can be rebuilt very easily. Therefore I would like to configure the VM to be preemptible rather than have it always be on.

I'm basing this deployment off of this repo https://github.com/docksal/sandbox-server/tree/develop/gcp-deployment-manager. Specifically, the contents of https://github.com/docksal/sandbox-server/blob/develop/gcp-deployment-manager/Docksal.jinja is what contains the server resource.

How can/should Docksal.jinja be modified to specify the VM should be preemptible?

Lester Peabody
  • 205
  • 1
  • 2
  • 9

1 Answers1

0

You need to add scheduling.preemptible=true to the instance resource properties.

...
# VM instance
- type: compute.v1.instance
  name: {{ instanceName }}
  properties:
    scheduling:
      preemptible: true
...
Lester Peabody
  • 205
  • 1
  • 2
  • 9