出现的问题: + rsync -avzP /mnt/workspace/df-admin/ root@192.168.0.153:/home/deploy/deep_fashion_targets/web /tmp/jenkins5788277461826608.sh: line 2: rsync: command not found Build step 'Execute shell' marked build as failure Finished: FAILURE 构建是执行shell e
[root@localhost usr]# sh test.sh command not found -bash: cd: usr: No such file or directory 这里碰到了一个问题,我用Xshell远程登录到服务器,直接可以执行我的一个脚本,这个脚本里有一些命令是在PATH路径下的. 但是在Jenkins里面直接执行脚本却报错了,说是找不到这些命令,最后我在执行脚本前先export PATH = /home/.... 把PATH设置了一下,结果就执行成功了,不知道为什么
之前在使用Jenkins执行远程shell脚本时,出现提示java: command not found:多方查找原因后发现是因为远程执行shell脚本时,不会自动加载环境变量,导致出现此错误,解决方案就是在脚本前加上这段代码即可source /etc/profile; source /etc/profile cd /root/shell sh erp-shop-h5-server.sh
执行shell出现bad interpreter:No such file or directory linux执行shell出现bad interpreter:No such file or directory的原因是文件格式的问题.这个文件是在Windows下编写的.换行的方式与Unix不一样,但是在VI下面如果不Set一下又完全看不出来. 解决方法:1.上传到linux主机运行 chmod +x back ./back 错误提示如下: bash: ./back : bad inter