< Back
Remove-BMServerRole
Post
NAME Remove-BMServerRole
SYNOPSIS
Removes a server role from BuildMaster.
SYNTAX
Remove-BMServerRole [-Session] <Object> [-Name] <String> [-WhatIf] [-Confirm] [<CommonParameters>]
DESCRIPTION
The `Remove-BMServerRole` removes a server role from BuildMaster. Pass the name of the role to remove to the
`Name` parameter. If the server role doesn't exist, nothing happens.
Pass the session to the BuildMaster instance where you want to delete the role to the `Session` parameter. Use
`New-BMSession` to create a session object.
This function uses BuildMaster's infrastructure management API.
PARAMETERS
-Session <Object>
An object representing the instance of BuildMaster to connect to. Use `New-BMSession` to create session
objects.
Required? true
Position? 1
Default value
Accept pipeline input? false
Accept wildcard characters? false
-Name <String>
The name of the role to remove.
Required? true
Position? 2
Default value
Accept pipeline input? true (ByPropertyName)
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:\\>Remove-BMServerRole -Session $session -Name 'Server Role'
Demonstrates how to delete a server role.
-------------------------- EXAMPLE 2 --------------------------
PS C:\\>Get-BMServerRole -Session $session -Name 'My Role' | Remove-BMServerRole -Session $session
Demonstrates that you can pipe the objects returned by `Get-BMServerRole` into `Remove-BMServerRole` to remove
those roles.
RELATED LINKS
SYNOPSIS
Removes a server role from BuildMaster.
SYNTAX
Remove-BMServerRole [-Session] <Object> [-Name] <String> [-WhatIf] [-Confirm] [<CommonParameters>]
DESCRIPTION
The `Remove-BMServerRole` removes a server role from BuildMaster. Pass the name of the role to remove to the
`Name` parameter. If the server role doesn't exist, nothing happens.
Pass the session to the BuildMaster instance where you want to delete the role to the `Session` parameter. Use
`New-BMSession` to create a session object.
This function uses BuildMaster's infrastructure management API.
PARAMETERS
-Session <Object>
An object representing the instance of BuildMaster to connect to. Use `New-BMSession` to create session
objects.
Required? true
Position? 1
Default value
Accept pipeline input? false
Accept wildcard characters? false
-Name <String>
The name of the role to remove.
Required? true
Position? 2
Default value
Accept pipeline input? true (ByPropertyName)
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:\\>Remove-BMServerRole -Session $session -Name 'Server Role'
Demonstrates how to delete a server role.
-------------------------- EXAMPLE 2 --------------------------
PS C:\\>Get-BMServerRole -Session $session -Name 'My Role' | Remove-BMServerRole -Session $session
Demonstrates that you can pipe the objects returned by `Get-BMServerRole` into `Remove-BMServerRole` to remove
those roles.
RELATED LINKS