Force Rundeck “Secure Remote Authentication” option to pass to script

生来就可爱ヽ(ⅴ<●) 提交于 2021-01-29 01:34:57

问题


SSH key authentication is frowned upon in my environment (a point I disagree with) so Rundeck users are forced into entering their SSH password at run time into a "Secure Remote Authentication" option. Short of setting up two separate options, one "Secure" to pass to the scripts and the other "Secure Remote Authentication" for authenticating the SSH sessions, is there any way to force the contents of a "Secure Remote Authentication" job option to also be passed to a script that the job is executing?


回答1:


Yep, I think what you are looking for is this:

Something like this in your node:

<node name="egon" description="egon" osFamily="unix"
username="rundeck"
hostname="egon"
ssh-authentication="password"
ssh-password-option="option.theSamePasswordOption"
sudo-command-enabled="true"
sudo-password-option="option.theSamePasswordOption" />

As long as that option is a 'Secure Remote Authentication' option, it should work for both cases.

I noticed that I had to remove the stored password option from the project settings in order for the authentication to use the passed in option value.



来源:https://stackoverflow.com/questions/27319740/force-rundeck-secure-remote-authentication-option-to-pass-to-script

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!