Remove-AzDevCenterUserEnvironment
Deletes an environment and all its associated resources
Syntax
Remove-AzDevCenterUserEnvironment
-Endpoint <String>
-Name <String>
-ProjectName <String>
[-UserId <String>]
[-DefaultProfile <PSObject>]
[-AsJob]
[-NoWait]
[-PassThru]
[-WhatIf]
[-Confirm]
[<CommonParameters>]
Remove-AzDevCenterUserEnvironment
-Endpoint <String>
-InputObject <IDevCenterdataIdentity>
[-DefaultProfile <PSObject>]
[-AsJob]
[-NoWait]
[-PassThru]
[-WhatIf]
[-Confirm]
[<CommonParameters>]
Remove-AzDevCenterUserEnvironment
-DevCenterName <String>
-InputObject <IDevCenterdataIdentity>
[-DefaultProfile <PSObject>]
[-AsJob]
[-NoWait]
[-PassThru]
[-WhatIf]
[-Confirm]
[<CommonParameters>]
Remove-AzDevCenterUserEnvironment
-DevCenterName <String>
-Name <String>
-ProjectName <String>
[-UserId <String>]
[-DefaultProfile <PSObject>]
[-AsJob]
[-NoWait]
[-PassThru]
[-WhatIf]
[-Confirm]
[<CommonParameters>]
Description
Deletes an environment and all its associated resources
Examples
Example 1: Delete an environment by endpoint
Remove-AzDevCenterUserEnvironment -Endpoint "https://8a40af38-3b4c-4672-a6a4-5e964b1870ed-contosodevcenter.centralus.devcenter.azure.com/" -ProjectName DevProject -UserId "me" -Name myEnv
This command deletes the environment "myEnv" under the project "DevProject" assigned to the currently signed-in user.
Example 2: Delete an environment by dev center
Remove-AzDevCenterUserEnvironment -DevCenterName Contoso -ProjectName DevProject -UserId "00aa00aa-bb11-cc22-dd33-44ee44ee44ee" -Name myEnv
This command deletes the environment "myEnv" under the project "DevProject" assigned to the user "00aa00aa-bb11-cc22-dd33-44ee44ee44ee".
Example 3: Delete an environment by endpoint and InputObject
$envInput = @{"UserId" = "00aa00aa-bb11-cc22-dd33-44ee44ee44ee"; "ProjectName" = "DevProject"; "EnvironmentName" = "myEnv" }
Remove-AzDevCenterUserEnvironment -Endpoint "https://8a40af38-3b4c-4672-a6a4-5e964b1870ed-contosodevcenter.centralus.devcenter.azure.com/" -InputObject $envInput
This command deletes the environment "myEnv" under the project "DevProject" assigned to the user "00aa00aa-bb11-cc22-dd33-44ee44ee44ee".
Example 4: Delete an environment by dev center and InputObject
$envInput = @{"UserId" = "me"; "ProjectName" = "DevProject"; "EnvironmentName" = "myEnv" }
Remove-AzDevCenterUserEnvironment -DevCenterName Contoso -InputObject $envInput
This command deletes the environment "myEnv" under the project "DevProject" assigned to the currently signed-in user.
Parameters
-AsJob
Run the command as a job
Type: | SwitchParameter |
Position: | Named |
Default value: | None |
Required: | False |
Accept pipeline input: | False |
Accept wildcard characters: | False |
-Confirm
Prompts you for confirmation before running the cmdlet.
Type: | SwitchParameter |
Aliases: | cf |
Position: | Named |
Default value: | None |
Required: | False |
Accept pipeline input: | False |
Accept wildcard characters: | False |
-DefaultProfile
The DefaultProfile parameter is not functional. Use the SubscriptionId parameter when available if executing the cmdlet against a different subscription.
Type: | PSObject |
Aliases: | AzureRMContext, AzureCredential |
Position: | Named |
Default value: | None |
Required: | False |
Accept pipeline input: | False |
Accept wildcard characters: | False |
-DevCenterName
The DevCenter upon which to execute operations.
Type: | String |
Aliases: | DevCenter |
Position: | Named |
Default value: | None |
Required: | True |
Accept pipeline input: | False |
Accept wildcard characters: | False |
-Endpoint
The DevCenter-specific URI to operate on.
Type: | String |
Position: | Named |
Default value: | None |
Required: | True |
Accept pipeline input: | False |
Accept wildcard characters: | False |
-InputObject
Identity Parameter To construct, see NOTES section for INPUTOBJECT properties and create a hash table.
Type: | IDevCenterdataIdentity |
Position: | Named |
Default value: | None |
Required: | True |
Accept pipeline input: | True |
Accept wildcard characters: | False |
-Name
The name of the environment.
Type: | String |
Aliases: | EnvironmentName |
Position: | Named |
Default value: | None |
Required: | True |
Accept pipeline input: | False |
Accept wildcard characters: | False |
-NoWait
Run the command asynchronously
Type: | SwitchParameter |
Position: | Named |
Default value: | None |
Required: | False |
Accept pipeline input: | False |
Accept wildcard characters: | False |
-PassThru
Returns true when the command succeeds
Type: | SwitchParameter |
Position: | Named |
Default value: | None |
Required: | False |
Accept pipeline input: | False |
Accept wildcard characters: | False |
-ProjectName
The DevCenter Project upon which to execute operations.
Type: | String |
Position: | Named |
Default value: | None |
Required: | True |
Accept pipeline input: | False |
Accept wildcard characters: | False |
-UserId
The AAD object id of the user. If value is 'me', the identity is taken from the authentication context.
Type: | String |
Position: | Named |
Default value: | "me" |
Required: | False |
Accept pipeline input: | False |
Accept wildcard characters: | False |
-WhatIf
Shows what would happen if the cmdlet runs. The cmdlet is not run.
Type: | SwitchParameter |
Aliases: | wi |
Position: | Named |
Default value: | None |
Required: | False |
Accept pipeline input: | False |
Accept wildcard characters: | False |
Inputs
Outputs
Azure PowerShell