gcloud alpha dns managed-zones update Stay organized with collections Save and categorize content based on your preferences.
- NAME
- gcloud alpha dns managed-zones update - update an existing Cloud DNS managed-zone
- SYNOPSIS
gcloud alpha dns managed-zones updateZONE[--async][--denial-of-existence=DENIAL_OF_EXISTENCE][--description=DESCRIPTION][--dnssec-state=DNSSEC_STATE][--forwarding-targets=[IP_ADDRESSES,…]][--gkeclusters=[GKECLUSTERS,…]][--ksk-algorithm=KSK_ALGORITHM][--ksk-key-length=KSK_KEY_LENGTH][--location=LOCATION][--[no-]log-dns-queries][--managed-reverse-lookup][--networks=[NETWORK,…]][--private-forwarding-targets=[IP_ADDRESSES,…]][--update-labels=[KEY=VALUE,…]][--zsk-algorithm=ZSK_ALGORITHM][--zsk-key-length=ZSK_KEY_LENGTH][--clear-labels|--remove-labels=[KEY,…]][--target-network=TARGET_NETWORK--target-project=TARGET_PROJECT][GCLOUD_WIDE_FLAG …]
- DESCRIPTION
(ALPHA)Update an existing Cloud DNS managed-zone.- EXAMPLES
- To change the description of a managed-zone, run:
gcloudalphadnsmanaged-zonesupdatemy-zone--description="Hello, world!"To change the description of a zonal managed-zone in us-east1-a, run:
gcloudalphadnsmanaged-zonesupdatemy-zone--description="Hello, world!"--location=us-east1-a - POSITIONAL ARGUMENTS
- Zone resource - The name of the managed-zone to be updated. This represents aCloud resource. (NOTE) Some attributes are not given arguments in this group butcan be set in other ways.
To set the
projectattribute:- provide the argument
zoneon the command line with a fullyspecified name; - provide the argument
--projecton the command line; - set the property
core/project.
This must be specified.
ZONE- ID of the zone or fully qualified identifier for the zone.
To set the
zoneattribute:- provide the argument
zoneon the command line.
- provide the argument
- provide the argument
- Zone resource - The name of the managed-zone to be updated. This represents aCloud resource. (NOTE) Some attributes are not given arguments in this group butcan be set in other ways.
- FLAGS
--async- Return immediately, without waiting for the operation in progress to complete.
--denial-of-existence=DENIAL_OF_EXISTENCE- Requires DNSSEC enabled.
DENIAL_OF_EXISTENCEmust be oneof:nsec,nsec3. --description=DESCRIPTION- Short description for the managed zone.
--dnssec-state=DNSSEC_STATE- The DNSSEC state for this managed zone.
DNSSEC_STATEmust be one of:off- Disable DNSSEC for the managed zone.
on- Enable DNSSEC for the managed zone.
transfer- Enable DNSSEC and allow transferring a signed zone in or out.
--forwarding-targets=[IP_ADDRESSES,…]- List of IPv4/IPv6 addresses or one domain name of the target name server thatthe zone will forward queries to. Ignored for
publicvisibility.Non-RFC1918 addresses will forward to the target through the Internet. RFC1918addresses will forward through the VPC. --gkeclusters=[GKECLUSTERS,…]- List of GKE clusters that the zone should be visible in if the zone visibilityis [private].
--ksk-algorithm=KSK_ALGORITHM- String mnemonic specifying the DNSSEC algorithm of the key-signing key. RequiresDNSSEC enabled.
KSK_ALGORITHMmust be one of:ecdsap256sha256,ecdsap384sha384,rsasha1,rsasha256,rsasha512. --ksk-key-length=KSK_KEY_LENGTH- Length of the key-signing key in bits. Requires DNSSEC enabled.
--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.
--[no-]log-dns-queries- Specifies whether to enable query logging. Defaults to False. Use
--log-dns-queriesto enable and--no-log-dns-queriesto disable. --managed-reverse-lookup- Specifies whether this zone is a managed reverse lookup zone, required for CloudDNS to correctly resolve Non-RFC1918 PTR records.
--networks=[NETWORK,…]- List of networks that the zone should be visible in if the zone visibility is[private].
--private-forwarding-targets=[IP_ADDRESSES,…]- List of IPv4/IPv6 addresses or one domain name of the target name server thatthe zone will forward queries to. Ignored for
publicvisibility.All addresses specified for this parameter will be reached through the VPC. --update-labels=[KEY=VALUE,…]- List of label KEY=VALUE pairs to update. If a label exists, its value ismodified. Otherwise, a new label is created.
Keys must start with a lowercase character and contain only hyphens(
-), underscores (_), lowercase characters, andnumbers. Values must contain only hyphens (-), underscores(_), lowercase characters, and numbers. --zsk-algorithm=ZSK_ALGORITHM- String mnemonic specifying the DNSSEC algorithm of the key-signing key. RequiresDNSSEC enabled.
ZSK_ALGORITHMmust be one of:ecdsap256sha256,ecdsap384sha384,rsasha1,rsasha256,rsasha512. --zsk-key-length=ZSK_KEY_LENGTH- Length of the zone-signing key in bits. Requires DNSSEC enabled.
- At most one of these can be specified:
--clear-labels- Remove all labels. If
--update-labelsis also specified then--clear-labelsis applied first.For example, to remove all labels:
gcloudalphadnsmanaged-zonesupdate--clear-labelsTo remove all existing labels and create two new labels,
andfoo:bazgcloudalphadnsmanaged-zonesupdate--clear-labels--update-labelsfoo=bar,baz=qux --remove-labels=[KEY,…]- List of label keys to remove. If a label does not exist it is silently ignored.If
--update-labelsis also specified then--update-labelsis applied first.
--target-network=TARGET_NETWORK- Network ID of the Google Compute Engine private network to forward queries to.
--target-project=TARGET_PROJECT- Project ID of the Google Compute Engine private network to forward queries to.
- 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 helpfor 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:
gclouddnsmanaged-zonesupdategcloudbetadnsmanaged-zonesupdate
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.