Skip to content

feat: add gcp get vm instance component#5011

Open
WashingtonKK wants to merge 7 commits into
superplanehq:mainfrom
WashingtonKK:gcp/get-vm
Open

feat: add gcp get vm instance component#5011
WashingtonKK wants to merge 7 commits into
superplanehq:mainfrom
WashingtonKK:gcp/get-vm

Conversation

@WashingtonKK
Copy link
Copy Markdown
Collaborator

@WashingtonKK WashingtonKK commented May 26, 2026

Summary

Adds a new Compute • Get VM Instance action to the GCP integration. It fetches the current state of a Compute Engine VM and emits its details on the default output channel.

What it does

  • Accepts a VM instance via the dropdown (zone-encoded path) or an expression chained from an upstream node (e.g. selfLink from gcp.createVM)
  • Resolves zone and name via the existing parseInstancePath helper (relative paths and full selfLink URLs both work)
  • Rejects cross-project selfLinks — the integration's bound project is authoritative
  • Fails loudly if the instance is not found, so stale expressions don't silently pass
  • Emits: instanceId, name, selfLink, status, zone, machineType, internalIP, externalIP

Use cases

  • Status checks — gate downstream steps on a VM being RUNNING
  • Detail lookup — surface IPs or machine type for later workflow nodes
  • Health gates — branch a workflow based on instance state

Demo Video

Signed-off-by: WashingtonKK <washingtonkigan@gmail.com>
- Introduced a new LinkCard for "Compute • Get VM Instance" in the GoogleCloud.mdx file.
- Added detailed documentation for the new component, including use cases, configuration options, output structure, and important notes.

Signed-off-by: WashingtonKK <washingtonkigan@gmail.com>
…ance

- Remove duplicate VMInstanceNodeMetadata type from get_vm_instance.go
- Remove duplicate ParseInstancePath export from list_resource_handler.go; reuse existing private parseInstancePath from delete_vm_instance.go
- Update get_vm_instance.go callers to use the private function
- Add missing Delete method to mockGetClient to satisfy Client interface
- Remove duplicate Test__ParseInstancePath from get_vm_instance_test.go

Co-Authored-By: WashingtonKK <washingtonkigan@gmail.com>
Signed-off-by: WashingtonKK <washingtonkigan@gmail.com>
@superplanehq-integration
Copy link
Copy Markdown

👋 Commands for maintainers:

  • /sp start - Start an ephemeral machine (takes ~30s)
  • /sp stop - Stop a running machine (auto-executed on pr close)

Signed-off-by: WashingtonKK <washingtonkigan@gmail.com>
Comment thread web_src/src/pages/workflowv2/mappers/gcp/get_vm_instance.ts Outdated
Comment thread pkg/integrations/gcp/compute/get_vm_instance.go
Signed-off-by: WashingtonKK <washingtonkigan@gmail.com>
Copy link
Copy Markdown
Contributor

@cursor cursor Bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Cursor Bugbot has reviewed your changes and found 1 potential issue.

Fix All in Cursor

❌ Bugbot Autofix is OFF. To automatically fix reported issues with cloud agents, enable autofix in the Cursor dashboard.

Reviewed by Cursor Bugbot for commit 07ba0bc. Configure here.

Comment thread web_src/src/pages/workflowv2/mappers/gcp/get_vm_instance.ts Outdated
Signed-off-by: WashingtonKK <washingtonkigan@gmail.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant