Issue while running script newman script on Octopus Server

nachiket.lotlikar's Avatar


20 May, 2017 03:40 AM


I have installed nodeJs and newman on Octopus server. I am able to successfully run Postman collection using newman by logging into Octopus Server. I have saved collection file on particular folder and I tried running powershell which does "newman run" of my postman collection. I have also ensured paths and postman collections, variables etc. are present.

After I was able to successfully run newman on Octopus Server, I tried running it during Octopus Deployment process by adding 'Run a Script' step. I ensured that powershell reaches out to correct path in Octopus Server. However, I am getting ''newman' is not recognized as an internal or external command' error in deployment step.

I also logged in to Octopus Server and used Calamari.exe run-script --script "filePath" to check if I can run script using Calamari, and I was able to run it successfully using Calamari.

It seems to break only from Octopus web portal.

Could you please let me know if I am missing something here?

Nachiket Lotlikar

  1. 1 Posted by nachiket.lotlik... on 20 May, 2017 01:27 PM

    nachiket.lotlikar's Avatar

    I was able to figure this out myself. If I am running directly on server below command worked

    Running Directly in PowerShell
    newman run "collectionPath"

    Running using Calamari run-script
    Calamari.exe run-script --script="pathToPowerShell"

    In order to run this using Octopus Portal, I had to do below
    cd C:\PostmanCollection\node_modules\newman\bin
    node newman run "collectionPath"

    It seems Calamari was not able to run node modules directly.

  2. nachiket.lotlikar closed this discussion on 20 May, 2017 01:27 PM.

Comments are currently closed for this discussion. You can start a new one.

Keyboard shortcuts


? Show this help
ESC Blurs the current field

Comment Form

r Focus the comment reply box
^ + ↩ Submit the comment

You can use Command ⌘ instead of Control ^ on Mac