8 lines
295 B
PowerShell
Executable File
8 lines
295 B
PowerShell
Executable File
#!/usr/bin/env pwsh
|
|
|
|
. /opt/idssys/powerwall/settings.ps1
|
|
|
|
Connect-VIServer -Server $args[0] -Protocol https -User $ESXiUsername -Password $ESXiPassword
|
|
|
|
Get-VM | Where {$_.PowerState -like '*On*' -and $_.Name -notlike '*CLS*' -and $_.Name -notlike '*iSCSI*'} | Shutdown-VMGuest -Confirm:$false
|