Skip to main content

instances_resource_policies

Creates, updates, deletes, gets or lists a instances_resource_policies resource.

Overview

Nameinstances_resource_policies
TypeResource
Idgoogle.compute.instances_resource_policies

Fields

SELECT not supported for this resource, use SHOW METHODS to view available operations for the resource.

Methods

NameAccessible byRequired ParamsDescription
add_resource_policiesINSERTinstance, project, zoneAdds existing resource policies to an instance. You can only add one policy right now which will be applied to this instance for scheduling live migrations.
remove_resource_policiesDELETEinstance, project, zoneRemoves resource policies from an instance.

INSERT example

Use the following StackQL query and manifest file to create a new instances_resource_policies resource.

/*+ create */
INSERT INTO google.compute.instances_resource_policies (
instance,
project,
zone,
resourcePolicies
)
SELECT
'{{ instance }}',
'{{ project }}',
'{{ zone }}',
'{{ resourcePolicies }}'
;

DELETE example

Deletes the specified instances_resource_policies resource.

/*+ delete */
DELETE FROM google.compute.instances_resource_policies
WHERE instance = '{{ instance }}'
AND project = '{{ project }}'
AND zone = '{{ zone }}';