PowerCLI Reference

vSphere Auto Deploy Reference

Remove-DeployRule

Synopsis

Removes a rule from the working rule set.

Syntax

Remove-DeployRule [-DeployRule] <DeployRule[]> [-Delete] [-NoActivate] [<CommonParameters>]
Remove-DeployRule [-At] <UInt32> [-Delete] [-NoActivate] [<CommonParameters>]

Related Commands

Add-DeployRule

Detailed Description

Removes a rule from the working rule set. By default, the working rule set is then activated. Use the "-Delete" parameter to permanently delete the rule from the Auto Deploy server.

You must have the "AutoDeploy.RuleSet.Edit" privilege on the root folder of vCenter Server to remove a rule from the rule set and the "AutoDeploy.Rule.Delete" privilege to delete the rule.

Parameters

NameTypeDescriptionRequired?Pipeline InputDefault Value
AtUInt32Index in the rule set that you want to remove.truefalse
DeployRuleDeployRule[]Rule to remove from the working rule set.truetrue (ByValue)
DeleteDelete the rule object. This flag will permanently delete the rule from the AutoDeploy server and remove it from any RuleSets that it was in.falsefalse
NoActivateSwitchParameterSpecify this parameter to only remove the rule to the working rule set. By default, the working rule set is activated after the change.falsefalse

Return Type

Notes

Examples

-------------- Example 1 --------------

C:\PS> Get-DeployRule "testrule" | Remove-DeployRule


Copyright © 1998 - 2011 VMware, Inc. All rights reserved.