6.7

Table Of Contents
2 Determine the location of a public software depot that contains the image profile that you want to use,
or define a custom image profile with vSphere ESXi Image Builder.
3 Run Add-EsxSoftwareDepot to add the software depot that contains the image profile to the
PowerCLI session.
Depot Type Cmdlet
Remote depot Run Add-EsxSoftwareDepot depot_url.
ZIP file a Download the ZIP file to a local file path or create a mount point local to the
PowerCLI machine.
b Run Add-EsxSoftwareDepot C:\file_path\my_offline_depot.zip.
4 Run Get-EsxImageProfile to see a list of image profiles, and decide which profile you want to use.
5 Run Copy-DeployRule and specify the ReplaceItem parameter to change the rule that assigns an
image profile to hosts.
The following cmdlet replaces the current image profile that the rule assigns to the host with the
my_new_imageprofile profile. After the cmdlet completes, myrule assigns the new image profile to
hosts. The old version of myrule is renamed and hidden.
Copy-DeployRule myrule -ReplaceItem my_new_imageprofile
6 Test the rule compliance for each host that you want to deploy the image to.
a Verify that you can access the host for which you want to test rule set compliance.
Get-VMHost -Name ESXi_hostname
b Run the cmdlet that tests rule set compliance for the host, and bind the return value to a variable
for later use.
$tr = Test-DeployRuleSetCompliance ESXi_hostname
c Examine the differences between the contents of the rule set and configuration of the host.
$tr.itemlist
The system returns a table of current and expected items if the host for which you want to test the
new rule set compliance is compliant with the active rule set.
CurrentItem ExpectedItem
----------- ------------
my_old_imageprofile my_new_imageprofile
d Remediate the host to use the revised rule set the next time you boot the host.
Repair-DeployRuleSetCompliance $tr
VMware ESXi Upgrade
VMware, Inc. 85