简体   繁体   中英

Get input job value to use it in a command execution Rundeck

My Rundeck detail:

Rundeck version: 2.10.7
install type: rpm
OS Name/version: CentOS 6.7
DB Type/version: h2

I want to get all data from a required input data and use it in a script execution as follows:

/home/user/script.sh INPUTDATA1 INPUTDATA2

I tried next variables but it does not work:

/home/user/script.sh $RD_OPTION_1 $RD_OPTION_2

What should I do?

I think about modifying the script.sh to get those input options as @option.1@ but I'd prefer to use the scripts without modifying them.

The convention is whatever is the field name that should be given after RD_OPTION_. For example if message is field name it will be $RD_OPTION_MESSAGE. Make sure your you are passing right names, based on your question, it expects field names 1 and 2. You can read more on this documentation

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM