File: //lib/google-cloud-sdk/lib/surface/redis/instances/update.yaml
- release_tracks: [ALPHA, BETA, GA]
help_text:
brief: |
Update Memorystore Redis instances.
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:
$ {command} my-redis-instance --display-name="Cache for Foo Service" \
--update-labels=env=test,service=foo
arguments:
resource:
spec: !REF googlecloudsdk.command_lib.redis.resources:instance
help_text: |
Arguments and flags that specify the Memorystore Redis instance you want
to update.
params:
- arg_name: display-name
api_field: instance.displayName
help_text: |
A human-readable name for the instance.
- arg_name: size
api_field: instance.memorySizeGb
type: long
help_text: |
The memory size of the instance in GiB.
- arg_name: enable-auth
api_field: instance.authEnabled
type: bool
action: store_true
release_tracks: [ALPHA, BETA]
help_text: |
Enables Redis AUTH for the instance.
additional_arguments_hook: googlecloudsdk.command_lib.redis.util:AdditionalInstanceUpdateArguments
labels:
api_field: instance.labels
async:
collection: redis.projects.locations.operations
request:
ALPHA:
api_version: v1alpha1
modify_request_hooks:
- googlecloudsdk.command_lib.redis.instances_update_util:CheckFieldsSpecifiedAlpha
- googlecloudsdk.command_lib.redis.instances_update_util:AddDisplayName
- googlecloudsdk.command_lib.redis.instances_update_util:AddSize
- googlecloudsdk.command_lib.redis.instances_update_util:RemoveRedisConfigs
- googlecloudsdk.command_lib.redis.instances_update_util:UpdateRedisConfigs
- googlecloudsdk.command_lib.redis.instances_update_util:UpdateAuthEnabled
BETA:
api_version: v1beta1
modify_request_hooks:
- googlecloudsdk.command_lib.redis.instances_update_util:CheckFieldsSpecifiedBeta
- googlecloudsdk.command_lib.redis.instances_update_util:AddDisplayName
- googlecloudsdk.command_lib.redis.instances_update_util:AddSize
- googlecloudsdk.command_lib.redis.instances_update_util:RemoveRedisConfigs
- googlecloudsdk.command_lib.redis.instances_update_util:UpdateRedisConfigs
- googlecloudsdk.command_lib.redis.instances_update_util:UpdateAuthEnabled
GA:
api_version: v1
modify_request_hooks:
- googlecloudsdk.command_lib.redis.instances_update_util:CheckFieldsSpecifiedGA
- googlecloudsdk.command_lib.redis.instances_update_util:AddDisplayName
- googlecloudsdk.command_lib.redis.instances_update_util:AddSize
- googlecloudsdk.command_lib.redis.instances_update_util:RemoveRedisConfigs
- googlecloudsdk.command_lib.redis.instances_update_util:UpdateRedisConfigs
collection: redis.projects.locations.instances
update:
read_modify_update: true
disable_auto_field_mask: true