Last active
September 5, 2019 07:43
-
-
Save D4R4/a444ae1d4a0d660bbc713e61edc8c6db to your computer and use it in GitHub Desktop.
This restores a backup from an ESXi host configuration profile local folder
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
$VCUSER = "qweqwe" #$Parameters.Get_Item("VCUSER") | |
$VCPASS = "qweqwe"#$Parameters.Get_Item("VCPASS") | |
$VCNAME = "qweqwe" #$Parameters.Get_Item("VCNAME") | |
Describe "Checking PowerCLI Cmdlets available" { | |
$cmdletname = "Connect-VIServer" | |
It "Checking $cmdletname is available" { | |
$command = Get-Command $cmdletname | |
$command | Select Name, Version | |
$command.Name| Should Be $cmdletname | |
} | |
} | |
Describe "Connect-VIServer Tests" { | |
$connection = Connect-VIServer $VCName -User $VCUser -password $VCPass | |
It "Connection is active" { | |
$Global:DefaultVIServer[0].isconnected | Should Be $true | |
} | |
Set-VMHostFirmware -VMHost qweqwe -Restore -SourcePath c:\CLI\configBundle-qweqwe.ptco.net.tgz -HostUser root -HostPassword qweqwe | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment