create_instance
Create a new Compute Engine instance on Google Cloud Platform by specifying project ID, zone, instance name, machine type, source image, disk size, network, and optional external IP.
Instructions
Create a new Compute Engine instance.
Args:
project_id: The ID of the GCP project
zone: The zone to create the instance in (e.g., "us-central1-a")
instance_name: The name for the new instance
machine_type: The machine type (e.g., "e2-medium")
source_image: The source image for the boot disk (e.g., "projects/debian-cloud/global/images/family/debian-11")
boot_disk_size_gb: The size of the boot disk in GB (default: 10)
network: The network to connect to (default: "default")
subnet: The subnetwork to connect to (optional)
external_ip: Whether to allocate an external IP (default: True)
Returns:
Status message indicating whether the instance was created successfully
Input Schema
Name | Required | Description | Default |
---|---|---|---|
boot_disk_size_gb | No | ||
external_ip | No | ||
instance_name | Yes | ||
machine_type | Yes | ||
network | No | default | |
project_id | Yes | ||
source_image | Yes | ||
subnet | No | ||
zone | Yes |
Input Schema (JSON Schema)
{
"properties": {
"boot_disk_size_gb": {
"default": 10,
"title": "Boot Disk Size Gb",
"type": "integer"
},
"external_ip": {
"default": true,
"title": "External Ip",
"type": "boolean"
},
"instance_name": {
"title": "Instance Name",
"type": "string"
},
"machine_type": {
"title": "Machine Type",
"type": "string"
},
"network": {
"default": "default",
"title": "Network",
"type": "string"
},
"project_id": {
"title": "Project Id",
"type": "string"
},
"source_image": {
"title": "Source Image",
"type": "string"
},
"subnet": {
"default": "",
"title": "Subnet",
"type": "string"
},
"zone": {
"title": "Zone",
"type": "string"
}
},
"required": [
"project_id",
"zone",
"instance_name",
"machine_type",
"source_image"
],
"title": "create_instanceArguments",
"type": "object"
}