def update(module, link, kind): auth = GcpSession(module, 'compute') return wait_for_operation(module, auth.patch(link, resource_to_request(module)))
def allow_global_access_update(module, request, response): auth = GcpSession(module, 'compute') auth.patch( ''.join(["https://www.googleapis.com/compute/v1/", "projects/{project}/regions/{region}/forwardingRules/{name}"]).format(**module.params), {u'allowGlobalAccess': module.params.get('allow_global_access')}, )
def update(module, link): auth = GcpSession(module, 'spanner') return wait_for_operation(module, auth.patch(link, resource_to_update(module)))
def update(module, link): auth = GcpSession(module, 'cloudbuild') return return_if_object(module, auth.patch(link, resource_to_request(module)))
def update(module, link, fetch): auth = GcpSession(module, 'redis') params = {'updateMask': updateMask(resource_to_request(module), response_to_hash(module, fetch))} request = resource_to_request(module) del request['name'] return wait_for_operation(module, auth.patch(link, request, params=params))
def routing_config_update(module, request, response): auth = GcpSession(module, 'compute') auth.patch( ''.join(["https://www.googleapis.com/compute/v1/", "projects/{project}/global/networks/{name}"]).format(**module.params), {u'routingConfig': NetworkRoutingconfig(module.params.get('routing_config', {}), module).to_request()}, )
def update(module, link, kind, fetch): update_fields(module, resource_to_request(module), response_to_hash(module, fetch)) auth = GcpSession(module, 'compute') return wait_for_operation(module, auth.patch(link, resource_to_request(module)))
def update(module, link, fetch): auth = GcpSession(module, 'pubsub') params = {'updateMask': updateMask(resource_to_request(module), response_to_hash(module, fetch))} request = resource_to_request(module) del request['name'] return return_if_object(module, auth.patch(link, request, params=params))
def update(module, link): auth = GcpSession(module, 'spanner') return return_if_object(module, auth.patch(link, resource_to_update(module)))
def secondary_ip_ranges_update(module, request, response): auth = GcpSession(module, 'compute') auth.patch( ''.join(["https://www.googleapis.com/compute/v1/", "projects/{project}/regions/{region}/subnetworks/{name}"]).format(**module.params), {u'secondaryIpRanges': SubnetworkSecondaryiprangesArray(module.params.get('secondary_ip_ranges', []), module).to_request()}, )