Virtual Machine Instance

A Virtual Machine Instance in Google Cloud (GCP) is a compute resource that provides on-demand, scalable virtual servers running on Google’s infrastructure. It allows you to choose machine types, operating systems, storage, and networking configurations to run applications or workloads. Instances can be customized for general-purpose, compute-optimized, or memory-optimized needs, and they integrate with other GCP services for security, monitoring, and automation.

gcp.compute_instance

Fields

TitleIDTypeData TypeDescription
_keycorestring
advanced_machine_featurescorejsonControls for advanced machine-related behavior features.
ancestorscorearray<string>
can_ip_forwardcoreboolAllows this instance to send and receive packets with non-matching destination or source IPs. This is required if you plan to use this instance to forward routes. For more information, see Enabling IP Forwarding .
confidential_instance_configcorejson
cpu_platformcorestring[Output Only] The CPU platform used by this instance.
creation_timestampcoretimestamp[Output Only] Creation timestamp in RFC3339 text format.
datadog_display_namecorestring
deletion_protectioncoreboolWhether the resource should be protected against deletion.
descriptioncorestringAn optional description of this resource. Provide this property when you create the resource.
diskscorejsonArray of disks associated with this instance. Persistent disks must be created before you can assign them.
display_devicecorejsonEnables display device for the instance.
gcp_statuscorestring[Output Only] The status of the instance. One of the following values: PROVISIONING, STAGING, RUNNING, STOPPING, SUSPENDING, SUSPENDED, REPAIRING, and TERMINATED. For more information about the status of the instance, see Instance life cycle. Possible values: ['DEPROVISIONING', 'PROVISIONING', 'REPAIRING', 'RUNNING', 'STAGING', 'STOPPED', 'STOPPING', 'SUSPENDED', 'SUSPENDING', 'TERMINATED']. Values descriptions: ['The instance is halted and we are performing tear down tasks like network deprogramming, releasing quota, IP, tearing down disks etc.', 'Resources are being allocated for the instance.', 'The instance is in repair.', 'The instance is running.', 'All required resources have been allocated and the instance is being started.', 'The instance has stopped successfully.', 'The instance is currently stopping (either being deleted or killed).', 'The instance has suspended.', 'The instance is suspending.', 'The instance has stopped (either by explicit action or underlying failure).']
guest_acceleratorscorejsonA list of the type and count of accelerator cards attached to the instance.
hostnamecorestringSpecifies the hostname of the instance. The specified hostname must be RFC1035 compliant. If hostname is not specified, the default hostname is [INSTANCE_NAME].c.[PROJECT_ID].internal when using the global DNS, and [INSTANCE_NAME].[ZONE].c.[PROJECT_ID].internal when using zonal DNS.
idcorestring[Output Only] The unique identifier for the resource. This identifier is defined by the server.
key_revocation_action_typecorestringKeyRevocationActionType of the instance. Supported options are "STOP" and "NONE". The default value is "NONE" if it is not specified.
kindcorestring[Output Only] Type of the resource. Always compute#instance for instances.
labelscorearray<string>Labels to apply to this instance. These can be later modified by the setLabels method.
last_start_timestampcorestring[Output Only] Last start timestamp in RFC3339 text format.
last_stop_timestampcorestring[Output Only] Last stop timestamp in RFC3339 text format.
last_suspended_timestampcorestring[Output Only] Last suspended timestamp in RFC3339 text format.
machine_typecorestringFull or partial URL of the machine type resource to use for this instance, in the format: zones/zone/machineTypes/machine-type. This is provided by the client when the instance is created. For example, the following is a valid partial url to a predefined machine type: zones/us-central1-f/machineTypes/n1-standard-1 To create a custom machine type, provide a URL to a machine type in the following format, where CPUS is 1 or an even number up to 32 (2, 4, 6, ... 24, etc), and MEMORY is the total memory for this instance. Memory must be a multiple of 256 MB and must be supplied in MB (e.g. 5 GB of memory is 5120 MB): zones/zone/machineTypes/custom-CPUS-MEMORY For example: zones/us-central1-f/machineTypes/custom-4-5120 For a full list of restrictions, read the Specifications for custom machine types.
metadatacorejsonThe metadata key/value pairs assigned to this instance. This includes metadata keys that were explicitly defined for the instance.
min_cpu_platformcorestringSpecifies a minimum CPU platform for the VM instance. Applicable values are the friendly names of CPU platforms, such as minCpuPlatform: "Intel Haswell" or minCpuPlatform: "Intel Sandy Bridge".
namecorestringThe name of the resource, provided by the client when initially creating the resource. The resource name must be 1-63 characters long, and comply with RFC1035. Specifically, the name must be 1-63 characters long and match the regular expression `[a-z]([-a-z0-9]*[a-z0-9])?` which means the first character must be a lowercase letter, and all following characters must be a dash, lowercase letter, or digit, except the last character, which cannot be a dash.
network_interfacescorejsonAn array of network configurations for this instance. These specify how interfaces are configured to interact with other network services, such as connecting to the internet. Multiple interfaces are supported per instance.
network_performance_configcorejson
organization_idcorestring
paramscorejsonInput only. [Input Only] Additional params passed with the request, but not persisted as part of resource payload.
parentcorestring
private_ipv6_google_accesscorestringThe private IPv6 google access type for the VM. If not specified, use INHERIT_FROM_SUBNETWORK as default.
project_idcorestring
project_numbercorestring
reservation_affinitycorejsonSpecifies the reservations that this instance can consume from.
resource_namecorestring
resource_policiescorearray<string>Resource policies applied to this instance.
resource_statuscorejson[Output Only] Specifies values set for instance attributes as compared to the values requested by user in the corresponding input only field.
satisfies_pzicorebool[Output Only] Reserved for future use.
satisfies_pzscorebool[Output Only] Reserved for future use.
schedulingcorejsonSets the scheduling options for this instance.
self_linkcorestring[Output Only] Server-defined URL for this resource.
service_accountscorejsonA list of service accounts, with their specified scopes, authorized for this instance. Only one service account per VM instance is supported. Service accounts generate access tokens that can be accessed through the metadata server and used to authenticate applications on the instance. See Service Accounts for more information.
shielded_instance_configcorejson
shielded_instance_integrity_policycorejson
source_machine_imagecorestringSource machine image
start_restrictedcorebool[Output Only] Whether a VM has been restricted for start because Compute Engine has detected suspicious activity.
status_messagecorestring[Output Only] An optional, human-readable explanation of the status.
tagscorehstore
zonecorestring[Output Only] URL of the zone where the instance resides. You must specify this field as part of the HTTP request URL. It is not settable as a field in the request body.