Prior to PowerShell 6.0 to elevate your session you ran the command
Start-Process powershell -Verb runAs
When trying to run the similar command in PowerShell 6.0
Start-Process pwsh -Verb runAs
You get this output:
Start-Process : The parameter '-Verb' is not supported for the cmdlet 'Start-Process' on this edition of PowerShell.
At line:1 char:1
+ Start-Process pwsh -Verb runAs
+ ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
+ CategoryInfo : NotImplemented: (:) [Start-Process], NotSupportedException
+ FullyQualifiedErrorId : NotSupportedException,Microsoft.PowerShell.Commands.StartProcessCommand
So how do I elevate to run as administrator in PowerShell 6.0?
I am running the PowerShell Windows Nano Server docker image (microsoft/powershell:nanoserver)