Add-SCUserRolePermission

Adds a permission to a user role.

Syntax

Add-SCUserRolePermission [-AllowLocalAdmin] [-Author] [-AuthorVMNetwork] [-CanReceive] [-CanShare]
 [-Checkpoint] [-CheckpointRestoreOnly] [-Deploy] [-DeployFromTemplateOnly] [-DeployShielded]
 [-JobVariable <String>] [-OnBehalfOfUser <String>] [-OnBehalfOfUserRole <UserRole>] [-PROTipID <Guid>]
 [-PauseAndResume] [-RemoteConnect] [-Remove] [-RunAsynchronously] [-Save] [-Shutdown] [-Start] [-Stop]
 [-Store] -UserRole <SelfServiceUserRole> [-VMMServer <ServerConnection>] [<CommonParameters>]
Add-SCUserRolePermission [-AllowLocalAdmin] [-Author] [-AuthorVMNetwork] [-CanReceive] [-CanShare]
 [-Checkpoint] [-CheckpointRestoreOnly] [-Cloud <Cloud>] [-Deploy] [-DeployFromTemplateOnly] [-DeployShielded]
 -JobGroup <Guid> [-JobVariable <String>] [-OnBehalfOfUser <String>] [-OnBehalfOfUserRole <UserRole>]
 [-PROTipID <Guid>] [-PauseAndResume] [-RemoteConnect] [-Remove] [-RunAsynchronously] [-Save] [-Shutdown]
 [-Start] [-Stop] [-Store] [-VMMServer <ServerConnection>] [<CommonParameters>]
Add-SCUserRolePermission [-AllowLocalAdmin] [-Checkpoint] [-CheckpointRestoreOnly] -Cloud <Cloud> [-Deploy]
 [-DeployFromTemplateOnly] [-DeployShielded] [-JobVariable <String>] [-OnBehalfOfUser <String>]
 [-OnBehalfOfUserRole <UserRole>] [-PROTipID <Guid>] [-PauseAndResume] [-RemoteConnect] [-Remove]
 [-RunAsynchronously] [-Save] [-Shutdown] [-Start] [-Stop] [-Store] -UserRole <SelfServiceUserRole>
 [-VMMServer <ServerConnection>] [<CommonParameters>]
Add-SCUserRolePermission [-AllowLocalAdmin] [-Checkpoint] [-CheckpointRestoreOnly] [-Deploy]
 [-DeployFromTemplateOnly] [-DeployShielded] [-JobVariable <String>] [-OnBehalfOfUser <String>]
 [-OnBehalfOfUserRole <UserRole>] [-PROTipID <Guid>] [-PauseAndResume] [-RemoteConnect] [-Remove]
 [-RunAsynchronously] [-Save] [-Shutdown] [-Start] [-Stop] [-Store] -UserRolePermission <UserRolePermission>
 [-VMMServer <ServerConnection>] [<CommonParameters>]

Description

The Add-SCUserRolePermission cmdlet grants a permission to a user role.

Parameters

-AllowLocalAdmin

Indicates that this cmdlet grants the Allow Local Admin permission.

Type:SwitchParameter
Required:False
Position:Named
Default value:None
Accept pipeline input:False
Accept wildcard characters:False
-Author

Indicates that this cmdlet grants the Author permission.

Type:SwitchParameter
Required:False
Position:Named
Default value:None
Accept pipeline input:False
Accept wildcard characters:False
-AuthorVMNetwork

Indicates that this cmdlet grants the Author VMNetwork permission.

Type:SwitchParameter
Required:False
Position:Named
Default value:None
Accept pipeline input:False
Accept wildcard characters:False
-CanReceive

Indicates that this cmdlet grants the Can Receive permission.

Type:SwitchParameter
Required:False
Position:Named
Default value:None
Accept pipeline input:False
Accept wildcard characters:False
-CanShare

Indicates that this cmdlet grants the Can Share permission.

Type:SwitchParameter
Required:False
Position:Named
Default value:None
Accept pipeline input:False
Accept wildcard characters:False
-Checkpoint

Indicates that this cmdlet grants the Can Checkpoint permission.

Type:SwitchParameter
Required:False
Position:Named
Default value:None
Accept pipeline input:False
Accept wildcard characters:False
-CheckpointRestoreOnly

Indicates that this cmdlet grants the Can Checkpoint Restore Only permission.

Type:SwitchParameter
Required:False
Position:Named
Default value:None
Accept pipeline input:False
Accept wildcard characters:False
-Cloud

Specifies a private cloud object for which this cmdlet modifies a user role.

Type:Cloud
Required:True
Position:Named
Default value:None
Accept pipeline input:False
Accept wildcard characters:False
-Deploy

Indicates that this cmdlet grants the Deploy virtual machine permission.

Type:SwitchParameter
Required:False
Position:Named
Default value:None
Accept pipeline input:False
Accept wildcard characters:False
-DeployFromTemplateOnly

Indicates that this cmdlet grants the Deploy From Template Only virtual machine permission.

Type:SwitchParameter
Required:False
Position:Named
Default value:None
Accept pipeline input:False
Accept wildcard characters:False
-DeployShielded

Indicates that this cmdlet grants the Deploy Shielded permission.

Type:SwitchParameter
Required:False
Position:Named
Default value:None
Accept pipeline input:False
Accept wildcard characters:False
-JobGroup

Specifies an identifier for a series of commands that runs as a set just before the final command that includes the same job group identifier runs.

Type:Guid
Required:True
Position:Named
Default value:None
Accept pipeline input:False
Accept wildcard characters:False
-JobVariable

Specifies a variable in which job progress is tracked and stored.

Type:String
Required:False
Position:Named
Default value:None
Accept pipeline input:False
Accept wildcard characters:False
-OnBehalfOfUser

Specifies a user name. This cmdlet operates on behalf of the user that this parameter specifies.

Type:String
Required:False
Position:Named
Default value:None
Accept pipeline input:False
Accept wildcard characters:False
-OnBehalfOfUserRole

Specifies a user role. To obtain a user role, use the Get-SCUserRole cmdlet. This cmdlet operates on behalf of the user role that this parameter specifies.

Type:UserRole
Required:False
Position:Named
Default value:None
Accept pipeline input:False
Accept wildcard characters:False
-PROTipID

Specifies the ID of the Performance and Resource Optimization tip (PRO tip) that triggered this action. This parameter lets you audit PRO tips.

Type:Guid
Required:False
Position:Named
Default value:None
Accept pipeline input:False
Accept wildcard characters:False
-PauseAndResume

Indicates that this cmdlet grants the Can Pause And Resume permission.

Type:SwitchParameter
Required:False
Position:Named
Default value:None
Accept pipeline input:False
Accept wildcard characters:False
-RemoteConnect

Indicates that this cmdlet grants the Remote Connect permission.

Type:SwitchParameter
Required:False
Position:Named
Default value:None
Accept pipeline input:False
Accept wildcard characters:False
-Remove

Indicates that this cmdlet grants the Can Remove permission.

Type:SwitchParameter
Required:False
Position:Named
Default value:None
Accept pipeline input:False
Accept wildcard characters:False
-RunAsynchronously

Indicates that the job runs asynchronously so that control returns to the command shell immediately.

Type:SwitchParameter
Required:False
Position:Named
Default value:None
Accept pipeline input:False
Accept wildcard characters:False
-Save

Indicates that this cmdlet grants the Can Save VM permission.

Type:SwitchParameter
Required:False
Position:Named
Default value:None
Accept pipeline input:False
Accept wildcard characters:False
-Shutdown

Indicates that this cmdlet grants the Can Shutdown virtual machine permission.

Type:SwitchParameter
Required:False
Position:Named
Default value:None
Accept pipeline input:False
Accept wildcard characters:False
-Start

Indicates that this cmdlet grants the Can Start virtual machine permission.

Type:SwitchParameter
Required:False
Position:Named
Default value:None
Accept pipeline input:False
Accept wildcard characters:False
-Stop

Indicates that this cmdlet grants the Can Stop virtual machine permission.

Type:SwitchParameter
Required:False
Position:Named
Default value:None
Accept pipeline input:False
Accept wildcard characters:False
-Store

Indicates that this cmdlet grants the Can Store virtual machine permission.

Type:SwitchParameter
Required:False
Position:Named
Default value:None
Accept pipeline input:False
Accept wildcard characters:False
-UserRole

Specifies a user role to which this cmdlet adds permissions.

Type:SelfServiceUserRole
Required:True
Position:Named
Default value:None
Accept pipeline input:True (ByValue)
Accept wildcard characters:False
-UserRolePermission

Specifies a UserRolePermission to which this cmdlet adds permissions. To obtain a user role permission, use the Get-SCUserRolePermission cmdlet.

Type:UserRolePermission
Required:True
Position:Named
Default value:None
Accept pipeline input:True (ByValue)
Accept wildcard characters:False
-VMMServer

Specifies a Virtual Machine Manager (VMM) server on which this cmdlet modifies a user role.

Type:ServerConnection
Required:False
Position:Named
Default value:None
Accept pipeline input:True (ByValue)
Accept wildcard characters:False

Outputs

UserRole

This cmdlet returns a **UserRole** object.