< Back
Grant-CServiceControlPermission
Post
NAME Grant-CServiceControlPermission
SYNOPSIS
Grants a user/group permission to start/stop (i.e. use PowerShell's `*-Service` cmdlets) a service.
SYNTAX
Grant-CServiceControlPermission [-ServiceName] <String> [-Identity] <String> [-WhatIf] [-Confirm]
[<CommonParameters>]
DESCRIPTION
By default, only Administrators are allowed to control a service. You may notice that when running the
`Stop-Service`, `Start-Service`, or `Restart-Service` cmdlets as a non-Administrator, you get permissions errors.
That's because you need to correct permissions. This function grants just the permissions needed to use
PowerShell's `Stop-Service`, `Start-Service`, and `Restart-Service` cmdlets to control a service.
PARAMETERS
-ServiceName <String>
The name of the service.
Required? true
Position? 1
Default value
Accept pipeline input? false
Accept wildcard characters? false
-Identity <String>
The user/group name being given access.
Required? true
Position? 2
Default value
Accept pipeline input? false
Accept wildcard characters? false
-WhatIf [<SwitchParameter>]
Required? false
Position? named
Default value
Accept pipeline input? false
Accept wildcard characters? false
-Confirm [<SwitchParameter>]
Required? false
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:\\>Grant-CServiceControlPermission -ServiceName CCService -Identity INITRODE\\Builders
Grants the INITRODE\\Builders group permission to control the CruiseControl.NET service.
RELATED LINKS
Get-CServicePermission
Grant-CServicePermission
Revoke-CServicePermission
SYNOPSIS
Grants a user/group permission to start/stop (i.e. use PowerShell's `*-Service` cmdlets) a service.
SYNTAX
Grant-CServiceControlPermission [-ServiceName] <String> [-Identity] <String> [-WhatIf] [-Confirm]
[<CommonParameters>]
DESCRIPTION
By default, only Administrators are allowed to control a service. You may notice that when running the
`Stop-Service`, `Start-Service`, or `Restart-Service` cmdlets as a non-Administrator, you get permissions errors.
That's because you need to correct permissions. This function grants just the permissions needed to use
PowerShell's `Stop-Service`, `Start-Service`, and `Restart-Service` cmdlets to control a service.
PARAMETERS
-ServiceName <String>
The name of the service.
Required? true
Position? 1
Default value
Accept pipeline input? false
Accept wildcard characters? false
-Identity <String>
The user/group name being given access.
Required? true
Position? 2
Default value
Accept pipeline input? false
Accept wildcard characters? false
-WhatIf [<SwitchParameter>]
Required? false
Position? named
Default value
Accept pipeline input? false
Accept wildcard characters? false
-Confirm [<SwitchParameter>]
Required? false
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:\\>Grant-CServiceControlPermission -ServiceName CCService -Identity INITRODE\\Builders
Grants the INITRODE\\Builders group permission to control the CruiseControl.NET service.
RELATED LINKS
Get-CServicePermission
Grant-CServicePermission
Revoke-CServicePermission