小编Poo*_*a R的帖子

jenkins上的交互式shell脚本

我是詹金斯的新手。我试图通过使用'使用ssh在远程主机上执行shell脚本'选项来调用jenkins中的远程shell脚本。如何在jenkins上获取用户对shell脚本的输入。

script:
echo "hello"
 read -p  "Choose your option : " ch
echo "Hi"
Run Code Online (Sandbox Code Playgroud)

在詹金斯上的输出:

Started by user anonymous
[EnvInject] - Loading node environment variables.
Building in workspace C:\Users\pooja_ravi\.jenkins\workspace\freeStyle
[SSH] executing pre build script:    

[SSH] executing post build script:

./testing.sh
./testing.sh[2]: read: no query process
hello
Hi
[SSH] exit-status: 0
Finished: SUCCESS
Run Code Online (Sandbox Code Playgroud)

提前致谢,

Pooja

ssh shell jenkins

5
推荐指数
1
解决办法
6453
查看次数

标签 统计

jenkins ×1

shell ×1

ssh ×1