How do you run a Powershell script from inside a GoAnywhere Director (Windows install)?

Answer:

Powershell seems to work a little bit differently than other executables. It was hanging because powershell was expecting some kind of input before running the script. So to get it working, we created an empty text file and used that as the ‘Input File’ on the advanced tab. Even though there is nothing in the file, it will complete the powershell script as expected this way.

<description>How to Execute a Powershell Script</description></project>

One thing to note, we only needed the –File argument but you may need additional arguments depending on your system’s setup. Some people have needed the –Noninteractive flag or use –ExecutionPolicy Bypass. Please refer to your Powershell manual for additional information.