I have packaged an application with the App Deployment Toolkit.
I install the application with the command:
Start-Process -FilePath $setupx64 -ArgumentList “/silent /install” -verb runas
That works. But only if the installation is running in the user context and not in the system context. If the installation runs in the system context (via SCCM) I need this command without the parameter -verb runas => otherwise it does not work
Start-Process -FilePath $setupx64 -ArgumentList “/silent /install”
How can I check in Deploy-Application.ps1 if the installation is started in the user context or in the system context?