Skip to content
Proud to collaborate with Microsoft for Startups

gcp.run.deploy_service ​

Deploy a container to Cloud Run

Deploys a container image to Google Cloud Run.

Creates or updates a Cloud Run service with the specified container image. The service is configured to allow unauthenticated access by default.

Inputs:

  • service_name: Name of the Cloud Run service (required).
  • image: Container image URL (required, e.g., gcr.io/project/image:tag).
  • region: GCP region where the service will be deployed (optional, default: us-central1).
  • port: Container port (optional, default: 8080).
  • memory: Memory allocated (optional, default: 256Mi).
  • cpu: CPU allocated (optional, default: 1).
  • min_instances: Minimum number of instances (optional, default: 0).
  • max_instances: Maximum number of instances (optional, default: 100).
  • connection_uuid: Cloud connection UUID for GCP credentials (required).

Outputs (terminal state_data):

  • service_name: str — Cloud Run service name
  • service_url: str — URL of the deployed service
  • region: str — region where deployed
  • image: str — container image URL
  • revision: str — revision name
  • ready: bool — whether service is ready

Compensation: Use gcp.run.delete_service to undo. Plugin required: context.get_plugin("gcp") must expose .get_run_client() and .get_project_id_for_connection().

Overview ​

PropertyValue
Workflow typeAtomic
LibraryBase
Version1.0

Input Schema ​

FieldTypeRequiredDefaultDescription
service_namestringYes—Cloud Run service name
imagestringYes—Container image URL
regionstringNo—GCP region (default: us-central1)
portintegerNo—Container port (default: 8080)
memorystringNo—Memory (default: 256Mi)
cpufloatNo—CPU (default: 1)
min_instancesintegerNo—Min instances (default: 0)
max_instancesintegerNo—Max instances (default: 100)
connection_uuiduuidYes—Cloud connection UUID for GCP credentials

Output Schema ​

FieldTypeRequiredDefaultDescription
imagestringNo——
readybooleanNo——
regionstringNo——
revisionintegerNo——
service_namestringNo——
service_urlstringNo——
connection_uuiduuidNo——
cpufloatNo——
max_instancesintegerNo——
memorystringNo——
min_instancesintegerNo——
portintegerNo——
failure_reasonstringNo——
failure_typestringNo——
failed_actionstringNo——
failed_at_statestringNo——
failed_stepstringNo——
failed_layerstringNo——
errorstringNo——
error_typestringNo——

States ​

StateInitialTerminalSuccessAuto-advanceDescription
pendingYesNo—execute—
completedNoYesYes——
failedNoYesNo——

Transitions ​

FromActionToDescription
pendingexecutecompleted—
* (any state)failfailed—

API Usage ​

bash
POST /api/v1/workflows/gcp.run.deploy_service/start
Content-Type: application/json

{ ... input fields ... }