1
0
Fork 0
mirror of https://github.com/imjasonh/gcloud-help synced 2026-07-10 19:31:55 +00:00
gcloud-help/gcloud/redis/instances/update
2022-03-01 04:29:52 +00:00

140 lines
5.2 KiB
Text

NAME
gcloud redis instances update - update Memorystore Redis instances
SYNOPSIS
gcloud redis instances update (INSTANCE : --region=REGION) [--async]
[--display-name=DISPLAY_NAME] [--enable-auth]
[--remove-redis-config=[KEY,...]] [--size=SIZE]
[--update-labels=[KEY=VALUE,...]] [--update-redis-config=KEY=VALUE]
[--clear-labels | --remove-labels=[KEY,...]] [GCLOUD_WIDE_FLAG ...]
DESCRIPTION
Update the metadata and/or configuration parameters of a Redis instance.
This command can fail for the following reasons:
▪ The instance specified does not exist.
▪ The active account does not have permission to update the given
instance.
EXAMPLES
To update a Redis instance with the name my-redis-instance to have the
display name "Cache for Foo Service", and add the two labels, env and
service, run:
$ gcloud redis instances update my-redis-instance \
--display-name="Cache for Foo Service" \
--update-labels=env=test,service=foo
POSITIONAL ARGUMENTS
Instance resource - Arguments and flags that specify the Memorystore Redis
instance you want to update. The arguments 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 in other ways. To set the
project attribute:
◆ provide the argument instance on the command line with a fully
specified name;
◆ provide the argument --project on the command line;
◆ set the property core/project.
This must be specified.
INSTANCE
ID of the instance or fully qualified identifier for the instance. To
set the instance attribute:
▸ provide the argument instance on the command line.
This positional must be specified if any of the other arguments in
this group are specified.
--region=REGION
The name of the Redis region of the instance. Overrides the default
redis/region property value for this command invocation.
To set the region attribute:
▸ provide the argument instance on the command line with a fully
specified name;
▸ provide the argument --region on the command line;
▸ set the property redis/region.
FLAGS
--async
Return immediately, without waiting for the operation in progress to
complete.
--display-name=DISPLAY_NAME
A human-readable name for the instance.
--enable-auth
Enables Redis AUTH for the instance.
--remove-redis-config=[KEY,...]
A list of Redis config parameters to remove. Removing a non-existent
config parameter is silently ignored.
--size=SIZE
The memory size of the instance in GiB.
--update-labels=[KEY=VALUE,...]
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
(-), underscores (_), lowercase characters, and numbers. Values must
contain only hyphens (-), underscores (_), lowercase characters, and
numbers.
--update-redis-config=KEY=VALUE
A list of Redis config KEY=VALUE pairs to update according to
http://cloud.google.com/memorystore/docs/reference/redis-configs. If a
config parameter is already set, its value is modified; otherwise a new
Redis config parameter is added. Currently, the only supported
parameters are:
Redis version 3.2 and newer: maxmemory-policy, notify-keyspace-events,
timeout.
Redis version 4.0 and newer: activedefrag, lfu-decay-time,
lfu-log-factor, maxmemory-gb.
Redis version 5.0 and newer: stream-node-max-bytes,
stream-node-max-entries.
At most one of these can be specified:
--clear-labels
Remove all labels. If --update-labels is also specified then
--clear-labels is applied first.
For example, to remove all labels:
$ gcloud redis instances update --clear-labels
To remove all existing labels and create two new labels, foo and baz:
$ gcloud redis instances update --clear-labels \
--update-labels foo=bar,baz=qux
--remove-labels=[KEY,...]
List of label keys to remove. If a label does not exist it is
silently ignored. If --update-labels is also specified then
--update-labels is applied first.
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.
API REFERENCE
This command uses the redis/v1 API. The full documentation for this API can
be found at: https://cloud.google.com/memorystore/docs/redis/
NOTES
These variants are also available:
$ gcloud alpha redis instances update
$ gcloud beta redis instances update