Hi,
I have create an action to change port group and it's working but now I need to change the network settings on guest (IP, subnetmask, gateway)
I give you my little action :
var psScript = ''
psScript +='Add-PSSnapin VMware.VimAutomation.Core\n';
psScript +='$username = "USERNAME"\n';
psScript +='$password = "PASSWORD"\n';
psScript +='\n';
psScript +='Connect-VIServer -Server "VCENTERSERVER" -User $username -Password $password\n';
psScript +='Get-VM '+ VMNAME + ' | Get-NetworkAdapter | Set-NetworkAdapter -NetworkName "PORTGROUP" -Confirm:$false\n';
psScript +='Disconnect-VIServer -Confirm:$False\n';
return System.getModule("com.vmware.library.powershell").invokeScript( host,psScript,sessionId) ;