< Back
Remove-GcIamPolicyBinding
Post
NAME Remove-GcIamPolicyBinding
SYNOPSIS
Removes an IAM policy binding to a project.
SYNTAX
Remove-GcIamPolicyBinding [-Project <string>] -User <string> [<CommonParameters>]
Remove-GcIamPolicyBinding [-Project <string>] -ServiceAccount <string> [<CommonParameters>]
Remove-GcIamPolicyBinding [-Project <string>] -Group <string> [<CommonParameters>]
Remove-GcIamPolicyBinding [-Project <string>] -Domain <string> [<CommonParameters>]
DESCRIPTION
Removes an IAM policy binding to a project. The cmdlet will use the default project if -Project is not used. If
the binding does not exist, the cmdlet will not raise error.
PARAMETERS
-Project <string>
The project for the IAM Policy Bindings. If not set via PowerShell parameter processing, will default to the
Cloud SDK's DefaultProject property.
Required? false
Position? named
Default value
Accept pipeline input? false
Accept wildcard characters? false
-User <string>
Email address that represents a specific Google account.
Required? true
Position? named
Default value
Accept pipeline input? false
Accept wildcard characters? false
-ServiceAccount <string>
Email address that represents a service account.
Required? true
Position? named
Default value
Accept pipeline input? false
Accept wildcard characters? false
-Group <string>
Email address that represents a Google group.
Required? true
Position? named
Default value
Accept pipeline input? false
Accept wildcard characters? false
-Domain <string>
A Google Apps domain name that represents all the users of that domain.
Required? true
Position? named
Default value
Accept pipeline input? false
Accept wildcard characters? false
<CommonParameters>
This cmdlet supports the common parameters: Verbose, Debug,
ErrorAction, ErrorVariable, WarningAction, WarningVariable,
OutBuffer, PipelineVariable, and OutVariable. For more information, see
about_CommonParameters (https:/go.microsoft.com/fwlink/?LinkID=113216).
INPUTS
OUTPUTS
---------- EXAMPLE 1 ----------
PS C:\\> Remove-GcIamPolicyBinding -Role roles/owner -User abc@google.com -Project "my-project"
This command removes the owner role of user abc@google.com in the project "my-project".
---------- EXAMPLE 2 ----------
PS C:\\> Remove-GcIamPolicyBinding -Role roles/container.admin -Group my-group@google.com
This command removes the container admin role of the group my-group@google.com in the default project.
---------- EXAMPLE 3 ----------
PS C:\\> Remove-GcIamPolicyBinding -Role roles/container.admin `
-ServiceAccount service@project.iam.gserviceaccount.com
This command removes the container admin role of the serviceaccount service@project.iam.gserviceaccount.com in the
default project.
---------- EXAMPLE 4 ----------
PS C:\\> Remove-GcIamPolicyBinding -Role roles/editor -Domain example.com
This command removes the editor role of all users of the domain example.com in the default project.
RELATED LINKS
[Google Cloud IAM] (https://cloud.google.com/iam/docs/overview)
SYNOPSIS
Removes an IAM policy binding to a project.
SYNTAX
Remove-GcIamPolicyBinding [-Project <string>] -User <string> [<CommonParameters>]
Remove-GcIamPolicyBinding [-Project <string>] -ServiceAccount <string> [<CommonParameters>]
Remove-GcIamPolicyBinding [-Project <string>] -Group <string> [<CommonParameters>]
Remove-GcIamPolicyBinding [-Project <string>] -Domain <string> [<CommonParameters>]
DESCRIPTION
Removes an IAM policy binding to a project. The cmdlet will use the default project if -Project is not used. If
the binding does not exist, the cmdlet will not raise error.
PARAMETERS
-Project <string>
The project for the IAM Policy Bindings. If not set via PowerShell parameter processing, will default to the
Cloud SDK's DefaultProject property.
Required? false
Position? named
Default value
Accept pipeline input? false
Accept wildcard characters? false
-User <string>
Email address that represents a specific Google account.
Required? true
Position? named
Default value
Accept pipeline input? false
Accept wildcard characters? false
-ServiceAccount <string>
Email address that represents a service account.
Required? true
Position? named
Default value
Accept pipeline input? false
Accept wildcard characters? false
-Group <string>
Email address that represents a Google group.
Required? true
Position? named
Default value
Accept pipeline input? false
Accept wildcard characters? false
-Domain <string>
A Google Apps domain name that represents all the users of that domain.
Required? true
Position? named
Default value
Accept pipeline input? false
Accept wildcard characters? false
<CommonParameters>
This cmdlet supports the common parameters: Verbose, Debug,
ErrorAction, ErrorVariable, WarningAction, WarningVariable,
OutBuffer, PipelineVariable, and OutVariable. For more information, see
about_CommonParameters (https:/go.microsoft.com/fwlink/?LinkID=113216).
INPUTS
OUTPUTS
---------- EXAMPLE 1 ----------
PS C:\\> Remove-GcIamPolicyBinding -Role roles/owner -User abc@google.com -Project "my-project"
This command removes the owner role of user abc@google.com in the project "my-project".
---------- EXAMPLE 2 ----------
PS C:\\> Remove-GcIamPolicyBinding -Role roles/container.admin -Group my-group@google.com
This command removes the container admin role of the group my-group@google.com in the default project.
---------- EXAMPLE 3 ----------
PS C:\\> Remove-GcIamPolicyBinding -Role roles/container.admin `
-ServiceAccount service@project.iam.gserviceaccount.com
This command removes the container admin role of the serviceaccount service@project.iam.gserviceaccount.com in the
default project.
---------- EXAMPLE 4 ----------
PS C:\\> Remove-GcIamPolicyBinding -Role roles/editor -Domain example.com
This command removes the editor role of all users of the domain example.com in the default project.
RELATED LINKS
[Google Cloud IAM] (https://cloud.google.com/iam/docs/overview)