cluster.provision-gcp-vm ​
Provision a GCP VM backing a VM-style cluster.
Overview ​
| Property | Value |
|---|---|
| Workflow type | Linear |
| Library | App-clusters-gcp |
| Version | 1.0 |
Input Schema ​
| Field | Type | Required | Default | Description |
|---|---|---|---|---|
organization_uuid | uuid | Yes | — | Organization UUID for audit and parent cluster correlation. |
gcp_connection_uuid | uuid | Yes | — | GCP CloudConnection UUID used for provider calls. |
project_id | string | Yes | — | GCP project ID. |
zone | string | Yes | — | GCE zone. |
cluster_name | string | Yes | — | Logical VM cluster name. |
vm_name | string | No | — | VM name; defaults to cluster_name. |
instance_type | string | No | — | GCE machine type. |
cpu | integer | No | — | vCPU count. |
memory_gb | integer | No | — | Memory GiB. |
image | string | No | — | VM OS image. |
startup_script | string | No | — | Optional startup script. |
metadata | json | No | — | VM metadata. |
labels | json | No | — | Labels carried as metadata. |
credential_payload | json | No | — | Optional Kubernetes credential payload when bootstrap supplied it externally. |
collect_kubeconfig | boolean | No | — | Collect kubeconfig from VM serial output after VM ensure. |
endpoint_host | string | No | — | Host/IP to write into kubeconfig server URL. |
api_server | string | No | — | Full Kubernetes API server URL override. |
serial_port_start | integer | No | — | Serial output byte offset for kubeconfig collection. |
timeout_seconds | integer | No | — | Kubeconfig collection timeout. |
poll_interval | integer | No | — | Kubeconfig collection poll interval. |
actor | string | No | — | Caller initiating the workflow. |
Output Schema ​
| Field | Type | Required | Default | Description |
|---|---|---|---|---|
organization_uuid | uuid | Yes | — | Organization UUID for audit and parent cluster correlation. |
gcp_connection_uuid | uuid | Yes | — | GCP CloudConnection UUID used for provider calls. |
project_id | string | Yes | — | GCP project ID. |
zone | string | Yes | — | GCE zone. |
cluster_name | string | Yes | — | Logical VM cluster name. |
vm_name | string | No | — | VM name; defaults to cluster_name. |
instance_type | string | No | — | GCE machine type. |
cpu | integer | No | — | vCPU count. |
memory_gb | integer | No | — | Memory GiB. |
image | string | No | — | VM OS image. |
startup_script | string | No | — | Optional startup script. |
metadata | json | No | — | VM metadata. |
labels | json | No | — | Labels carried as metadata. |
credential_payload | json | No | — | Optional Kubernetes credential payload when bootstrap supplied it externally. |
collect_kubeconfig | boolean | No | — | Collect kubeconfig from VM serial output after VM ensure. |
endpoint_host | string | No | — | Host/IP to write into kubeconfig server URL. |
api_server | string | No | — | Full Kubernetes API server URL override. |
serial_port_start | integer | No | — | Serial output byte offset for kubeconfig collection. |
timeout_seconds | integer | No | — | Kubeconfig collection timeout. |
poll_interval | integer | No | — | Kubeconfig collection poll interval. |
actor | string | No | — | Caller initiating the workflow. |
ensure_vm | json | No | — | Output from gcp.compute.vm.ensure. |
collect_kubeconfig_result | json | No | — | Output from cluster.gcp-vm.collect-kubeconfig. |
provider_resource_id | string | No | — | Provider VM resource ID. |
provider_cluster_ref | string | No | — | Provider VM cluster reference. |
status | string | No | — | Normalized provider status. |
phase | string | No | — | Raw VM phase. |
ready | boolean | No | — | True when backing VM is available. |
completed_at | string | No | — | ISO completion timestamp. |
failure_reason | string | No | — | — |
failed_step | json | No | — | — |
failed_layer | json | No | — | — |
failed_at_state | json | No | — | — |
error | string | No | — | — |
error_type | string | No | — | — |
States ​
| State | Initial | Terminal | Success | Auto-advance | Description |
|---|---|---|---|---|---|
pending | Yes | No | — | ensure_vm | — |
collecting_kubeconfig | No | No | — | complete | — |
ensuring_vm | No | No | — | collect_kubeconfig | — |
completed | No | Yes | Yes | — | — |
failed | No | Yes | No | — | — |
State Diagram ​
Transitions ​
| From | Action | To | Description |
|---|---|---|---|
pending | ensure_vm | ensuring_vm | — |
ensuring_vm | collect_kubeconfig | collecting_kubeconfig | — |
collecting_kubeconfig | complete | completed | — |
* (any state) | fail | failed | — |
API Usage ​
bash
POST /api/workflows/start
Content-Type: application/json
{
"workflow_type": "cluster.provision-gcp-vm",
"initial_data": {
"organization_uuid": "value",
"gcp_connection_uuid": "value",
"project_id": "value",
"zone": "value"
}
}