File: //snap/google-cloud-cli/current/help/man/man1/gcloud_alpha_compute_forwarding-rules_update.1
.TH "GCLOUD_ALPHA_COMPUTE_FORWARDING\-RULES_UPDATE" 1
.SH "NAME"
.HP
gcloud alpha compute forwarding\-rules update \- update a Compute Engine forwarding rule
.SH "SYNOPSIS"
.HP
\f5gcloud alpha compute forwarding\-rules update\fR \fINAME\fR [\fB\-\-allow\-global\-access\fR] [\fB\-\-allow\-psc\-global\-access\fR] [\fB\-\-external\-managed\-backend\-bucket\-migration\-testing\-percentage\fR=\fIEXTERNAL_MANAGED_BACKEND_BUCKET_MIGRATION_TESTING_PERCENTAGE\fR] [\fB\-\-load\-balancing\-scheme\fR=\fILOAD_BALANCING_SCHEME\fR] [\fB\-\-network\-tier\fR=\fINETWORK_TIER\fR] [\fB\-\-source\-ip\-ranges\fR=\fISOURCE_IP_RANGE\fR,[...]] [\fB\-\-update\-labels\fR=[\fIKEY\fR=\fIVALUE\fR,...]] [\fB\-\-clear\-external\-managed\-backend\-bucket\-migration\-state\fR\ |\ \fB\-\-external\-managed\-backend\-bucket\-migration\-state\fR=\fIEXTERNAL_MANAGED_BACKEND_BUCKET_MIGRATION_STATE\fR] [\fB\-\-clear\-labels\fR\ |\ \fB\-\-remove\-labels\fR=[\fIKEY\fR,...]] [\fB\-\-global\fR\ |\ \fB\-\-region\fR=\fIREGION\fR] [\fIGCLOUD_WIDE_FLAG\ ...\fR]
.SH "DESCRIPTION"
\fB(ALPHA)\fR \fBgcloud alpha compute forwarding\-rules update\fR updates
labels, global access and network tier for a Compute Engine forwarding rule.
.SH "EXAMPLES"
To update the forwarding rule to allow global access, run:
.RS 2m
$ gcloud alpha compute forwarding\-rules update example\-fr \e
\-\-allow\-global\-access \-\-region=us\-central1
.RE
To add/update labels \f5\fIk0\fR\fR and \f5\fIk1\fR\fR and remove labels with
key \f5\fIk3\fR\fR , run:
.RS 2m
$ gcloud alpha compute forwarding\-rules update example\-fr \e
\-\-region=us\-central1 \-\-update\-labels=k0=value1,k1=value2 \e
\-\-remove\-labels=k3
.RE
Labels can be used to identify the forwarding rule and to filter them as in
.RS 2m
$ gcloud alpha compute forwarding\-rules list \e
\-\-filter='labels.k1:value2'
.RE
To list existing labels, run:
.RS 2m
$ gcloud alpha compute forwarding\-rules describe example\-fr \e
\-\-format="default(labels)"
.RE
.SH "POSITIONAL ARGUMENTS"
.RS 2m
.TP 2m
\fINAME\fR
Name of the forwarding rule to operate on.
.RE
.sp
.SH "FLAGS"
.RS 2m
.TP 2m
\fB\-\-allow\-global\-access\fR
If True, then clients from all regions can access this internal forwarding rule.
This can only be specified for forwarding rules with the LOAD_BALANCING_SCHEME
set to INTERNAL or INTERNAL_MANAGED. For forwarding rules of type INTERNAL, the
target must be either a backend service or a target instance.
.TP 2m
\fB\-\-allow\-psc\-global\-access\fR
If specified, clients from all regions can access this Private Service Connect
forwarding rule. This can only be specified if the forwarding rule's target is a
service attachment (\-\-target\-service\-attachment).
.TP 2m
\fB\-\-external\-managed\-backend\-bucket\-migration\-testing\-percentage\fR=\fIEXTERNAL_MANAGED_BACKEND_BUCKET_MIGRATION_TESTING_PERCENTAGE\fR
Determines the fraction of requests that should be processed by the Global
external Application Load Balancer.
The value of this field must be in the range [0, 100].
.TP 2m
\fB\-\-load\-balancing\-scheme\fR=\fILOAD_BALANCING_SCHEME\fR
Only for the Global external Application Load Balancer migration.
The value of this field must be EXTERNAL or EXTERNAL_MANAGED.
\fILOAD_BALANCING_SCHEME\fR must be one of: \fBEXTERNAL\fR,
\fBEXTERNAL_MANAGED\fR.
.TP 2m
\fB\-\-network\-tier\fR=\fINETWORK_TIER\fR
Update the network tier of a forwarding rule. It does not allow to change from
\f5PREMIUM\fR to \f5STANDARD\fR and visa versa.
.TP 2m
\fB\-\-source\-ip\-ranges\fR=\fISOURCE_IP_RANGE\fR,[...]
List of comma\-separated IP addresses or IP ranges. If set, this forwarding rule
only forwards traffic when the packet's source IP address matches one of the IP
ranges set here.
.TP 2m
\fB\-\-update\-labels\fR=[\fIKEY\fR=\fIVALUE\fR,...]
List of label KEY=VALUE pairs to update. If a label exists, its value is
modified. Otherwise, a new label is created.
Keys must start with a lowercase character and contain only hyphens (\f5\-\fR),
underscores (\f5_\fR), lowercase characters, and numbers. Values must contain
only hyphens (\f5\-\fR), underscores (\f5_\fR), lowercase characters, and
numbers.
.TP 2m
At most one of these can be specified:
.RS 2m
.TP 2m
\fB\-\-clear\-external\-managed\-backend\-bucket\-migration\-state\fR
Clears current state of external managed migration.
.TP 2m
\fB\-\-external\-managed\-backend\-bucket\-migration\-state\fR=\fIEXTERNAL_MANAGED_BACKEND_BUCKET_MIGRATION_STATE\fR
Specifies the migration state. Possible values are PREPARE, TEST_BY_PERCENTAGE,
and TEST_ALL_TRAFFIC.
To begin the migration from EXTERNAL to EXTERNAL_MANAGED, the state must be
changed to PREPARE. The state must be changed to TEST_ALL_TRAFFIC before the
loadBalancingScheme can be changed to EXTERNAL_MANAGED. Optionally, the
TEST_BY_PERCENTAGE state can be used to migrate traffic to backend buckets
attached to this forwarding rule by percentage using the
\-\-external\-managed\-backend\-bucket\-migration\-testing\-percentage flag.
\fIEXTERNAL_MANAGED_BACKEND_BUCKET_MIGRATION_STATE\fR must be one of:
\fBPREPARE\fR, \fBTEST_BY_PERCENTAGE\fR, \fBTEST_ALL_TRAFFIC\fR.
.RE
.sp
.TP 2m
At most one of these can be specified:
.RS 2m
.TP 2m
\fB\-\-clear\-labels\fR
Remove all labels. If \f5\-\-update\-labels\fR is also specified then
\f5\-\-clear\-labels\fR is applied first.
For example, to remove all labels:
.RS 2m
$ gcloud alpha compute forwarding\-rules update \-\-clear\-labels
.RE
To remove all existing labels and create two new labels, \f5\fIfoo\fR\fR and
\f5\fIbaz\fR\fR:
.RS 2m
$ gcloud alpha compute forwarding\-rules update \-\-clear\-labels \e
\-\-update\-labels foo=bar,baz=qux
.RE
.TP 2m
\fB\-\-remove\-labels\fR=[\fIKEY\fR,...]
List of label keys to remove. If a label does not exist it is silently ignored.
If \f5\-\-update\-labels\fR is also specified then \f5\-\-update\-labels\fR is
applied first.
.RE
.sp
.TP 2m
At most one of these can be specified:
.RS 2m
.TP 2m
\fB\-\-global\fR
If set, the forwarding rule is global.
.TP 2m
\fB\-\-region\fR=\fIREGION\fR
Region of the forwarding rule to operate on. If not specified, you might be
prompted to select a region (interactive mode only).
To avoid prompting when this flag is omitted, you can set the
\f5\fIcompute/region\fR\fR property:
.RS 2m
$ gcloud config set compute/region REGION
.RE
A list of regions can be fetched by running:
.RS 2m
$ gcloud compute regions list
.RE
To unset the property, run:
.RS 2m
$ gcloud config unset compute/region
.RE
Alternatively, the region can be stored in the environment variable
\f5\fICLOUDSDK_COMPUTE_REGION\fR\fR.
.RE
.RE
.sp
.SH "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 \fB$ gcloud help\fR for details.
.SH "NOTES"
This command is currently in alpha and might change without notice. If this
command fails with API permission errors despite specifying the correct project,
you might be trying to access an API with an invitation\-only early access
allowlist. These variants are also available:
.RS 2m
$ gcloud compute forwarding\-rules update
.RE
.RS 2m
$ gcloud beta compute forwarding\-rules update
.RE