Outra maneira de quebrar a noz sem ter que alterar a configuração do aplicativo sob implantação:
# increase memory available to WsMan (run from elevated PS instance on remote machine)
set-item wsman:localhost\Shell\MaxMemoryPerShellMB 2048
# for PowerShell v3 or higher this line is also necessary
Set-Item WSMan:\localhost\Plugin\Microsoft.PowerShell\Quotas\MaxMemoryPerShellMB 2048
# add remote work to script on remote server, and then call that script from the local script
invoke-command $remoteServer { param($remoteScript, $arg1, $arg2, $arg3) powershell $script $arg1 $arg2 $arg3 } -ArgumentList $remoteScript, $arg1, $arg2, $arg3