gcloud alpha dns response-policies rules update

NAME
gcloud alpha dns response-policies rules update - updates a new Cloud DNS response policy rule
SYNOPSIS
gcloud alpha dns response-policies rules update(RESPONSE_POLICY_RULE :--response-policy=RESPONSE_POLICY)[--behavior=BEHAVIOR][--dns-name=DNS_NAME][--local-data=[LOCAL_DATA,…]][--location=LOCATION][GCLOUD_WIDE_FLAG]
DESCRIPTION
(ALPHA) This command updates a new Cloud DNS response policy rule.
EXAMPLES
To update a new response policy rule with DNS name, run:
gcloudalphadnsresponse-policiesrulesupdatemyresponsepolicyrule--response-policy="myresponsepolicy"--dns-name="www.newzone.com."# pylint: disable=line-too-long

To update a new response policy rule with local data rrsets, run:

gcloudalphadnsresponse-policiesrulesupdatemyresponsepolicyrule--response-policy="myresponsepolicy"--local-data=name=www.zone.com.,type=A,ttl=21600,rrdatas=1.2.3.4

To update a new response policy rule with behavior, run:

gcloudalphadnsresponse-policiesrulesupdatemyresponsepolicyrule--response-policy="myresponsepolicy"--behavior=bypassResponsePolicy
POSITIONAL ARGUMENTS
Response policy rule resource - The response policy rule to update. Thearguments in this group can be used to specify the attributes of this resource.(NOTE) Some attributes are not given arguments in this group but can be set inother ways.

To set theproject attribute:

  • provide the argumentresponse_policy_rule on the command line witha fully specified name;
  • set the propertycore/project.

This must be specified.

RESPONSE_POLICY_RULE
ID of the response_policy_rule or fully qualified identifier for theresponse_policy_rule.

To set theresponse-policy-rule attribute:

  • provide the argumentresponse_policy_rule on the command line.

This positional argument must be specified if any of the other arguments in thisgroup are specified.

--response-policy=RESPONSE_POLICY
The Cloud DNS response policy name response_policy_rule.

To set theresponse-policy attribute:

  • provide the argumentresponse_policy_rule on the command line witha fully specified name;
  • provide the argument--response-policy on the command line.
FLAGS
--behavior=BEHAVIOR
The response policy rule query behavior.BEHAVIOR mustbe one of:behaviorUnspecified,bypassResponsePolicy.
--dns-name=DNS_NAME
DNS name (wildcard or exact) to apply this rule to.
--local-data=[LOCAL_DATA,…]
All resource record sets for this selector, one per resource record type. Thename must match the dns_name.

This is a repeated argument that can be specified multiple times to specifymultiple local data rrsets. (e.g.--local-data=name="zone.com.",type="A",ttl=21600,rrdata="1.2.3.4 "--local-data=name="www.zone.com.",type="CNAME",ttl=21600,rrdata="1.2.3.4|5.6.7.8")

name
The DnsName of a resource record set.
type
Type of all resource records in this set. For example, A, AAAA, SOA, MX, NS, TXT…
ttl
Number of seconds that this ResourceRecordSet can be cached by resolvers.
rrdatas
The list of datas for this record, split by "|".
--location=LOCATION
Specifies the desired service location the request is sent to. Defaults to CloudDNS global service. Use --location=global if you want to target the globalservice.
GCLOUD WIDE FLAGS
These flags are available to all commands:--access-token-file,--account,--billing-project,--configuration,--flags-file,--flatten,--format,--help,--impersonate-service-account,--log-http,--project,--quiet,--trace-token,--user-output-enabled,--verbosity.

Run$gcloud help for details.

NOTES
This command is currently in alpha and might change without notice. If thiscommand fails with API permission errors despite specifying the correct project,you might be trying to access an API with an invitation-only early accessallowlist. These variants are also available:
gclouddnsresponse-policiesrulesupdate
gcloudbetadnsresponse-policiesrulesupdate

Except as otherwise noted, the content of this page is licensed under theCreative Commons Attribution 4.0 License, and code samples are licensed under theApache 2.0 License. For details, see theGoogle Developers Site Policies. Java is a registered trademark of Oracle and/or its affiliates.

Last updated 2025-06-17 UTC.