Rundeck .. calling Powershell 7

14 views
Skip to first unread message

Roger McCarrick

unread,
Jun 13, 2024, 4:18:07 PMJun 13
to rundeck-discuss
My Rundeck jobs call powershell scripts on a Windows node.
The step in the Rundeck job is a command pointing at E:\path\script.ps1.
When the ps1 runs, it calls powershell 5 by default.
I want to keep most on powershell 5, but some on PS7.
How do I call a ps1 and make it run in PS7?

thanks 


rac...@rundeck.com

unread,
Jun 13, 2024, 4:38:48 PMJun 13
to rundeck-discuss

Hi Roger,

You can set the default interpreter in your “script” / “script file or URL” steps (the “Invocation String” field). Here you can see the different PS interpreter’s locations.

Additionally, you can use a list option with different paths and then, pass them to that field (something like ${option.my_ps_interpreter}), to select the default interpreter.

Regards.

Reply all
Reply to author
Forward
0 new messages