File: //snap/google-cloud-cli/396/help/man/man1/gcloud_kms_keyrings_set-iam-policy.1
.TH "GCLOUD_KMS_KEYRINGS_SET\-IAM\-POLICY" 1
.SH "NAME"
.HP
gcloud kms keyrings set\-iam\-policy \- set the IAM policy for a keyring
.SH "SYNOPSIS"
.HP
\f5gcloud kms keyrings set\-iam\-policy\fR \fIKEYRING\fR \fIPOLICY_FILE\fR [\fB\-\-location\fR=\fILOCATION\fR] [\fIGCLOUD_WIDE_FLAG\ ...\fR]
.SH "DESCRIPTION"
Sets the IAM policy for the given keyring as defined in a JSON or YAML file.
See https://cloud.google.com/iam/docs/managing\-policies for details of the
policy file format and contents.
.SH "EXAMPLES"
The following command will read am IAM policy defined in a JSON file
\'policy.json' and set it for the keyring \f5fellowship\fR with location
\f5global\fR:
.RS 2m
$ gcloud kms keyrings set\-iam\-policy fellowship policy.json \e
\-\-location=global
.RE
.SH "POSITIONAL ARGUMENTS"
.RS 2m
.TP 2m
\fIKEYRING\fR
Name of the key ring whose IAM policy to update.
.TP 2m
\fIPOLICY_FILE\fR
JSON or YAML file with the IAM policy
.RE
.sp
.SH "FLAGS"
.RS 2m
.TP 2m
\fB\-\-location\fR=\fILOCATION\fR
Location of the keyring.
.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"
These variants are also available:
.RS 2m
$ gcloud alpha kms keyrings set\-iam\-policy
.RE
.RS 2m
$ gcloud beta kms keyrings set\-iam\-policy
.RE