[help] is it possible to pass script name as variable to "script file or url" step in workflow

Skip to first unread message

Manoj B

Apr 5, 2023, 9:06:52 AM4/5/23
to rundeck-discuss
    I have an option names "script_name". 

Screenshot 2023-04-04 at 7.03.11 PM.png

 I want to use that variable in "script file or url" step. Below screenshot depicts my trial.
Screenshot 2023-04-04 at 7.06.16 PM.png
But I am getting File not found error. Please help me!
Screenshot 2023-04-04 at 7.10.24 PM.png


Apr 5, 2023, 9:22:25 AM4/5/23
to rundeck-discuss

I reproduced your issue. When you use a full path in an option Rundeck uses the Rundeck base path and then put the rest of the option content.

So, a good workaround here could be to put the base path in the "File Path or URL" textbox (like /opt/${option.myoption})

And, on the option field put the rest of the path (like /scripts/myscript.sh).

Could you open a new issue here?

A tip: use the full path in the "invocation script" textbox, like "/bin/sh" or "/bin/bash").


Manoj B

Apr 6, 2023, 10:19:07 AM4/6/23
to rundeck...@googlegroups.com
Hi @racuna,

 Thank you for your help. Your work around helped !

Screenshot 2023-04-06 at 7.47.05 PM.png

You received this message because you are subscribed to a topic in the Google Groups "rundeck-discuss" group.
To unsubscribe from this topic, visit https://groups.google.com/d/topic/rundeck-discuss/A8nchEutRrQ/unsubscribe.
To unsubscribe from this group and all its topics, send an email to rundeck-discu...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/rundeck-discuss/a1ac6933-fa86-4161-bde0-8cb1797ebf19n%40googlegroups.com.


Apr 6, 2023, 10:36:31 AM4/6/23
to rundeck-discuss
Awesome! Happy to help!
Reply all
Reply to author
0 new messages