9fe2 Jenkins中shell-script执行报错sh: line 2: npm: command not found
2018-03-16 09:57
656 查看
<1>本地执行npm run build--正常
<2>查看环境变量--正常
[root@localhost bin]# echo $PATH
/usr/local/node/bin:/usr/local/nginx/sbin:/usr/local/node/bin:
<3>将shell中的script的npm command换成绝对路径
报错:/usr/bin/env: node: No such file or directory
<4>添加node软链接:ln -s /usr/local/node/bin/node /usr/bin/node<5>Jenkins构建编译OK
<2>查看环境变量--正常
[root@localhost bin]# echo $PATH
/usr/local/node/bin:/usr/local/nginx/sbin:/usr/local/node/bin:
<3>将shell中的script的npm command换成绝对路径
报错:/usr/bin/env: node: No such file or directory
<4>添加node软链接:ln -s /usr/local/node/bin/node /usr/bin/node<5>Jenkins构建编译OK
相关文章推荐
- Cronjob 定时执行 pentaho job(解决spoon.sh command line not found 问题)
- jenkins执行shell命令,有时会提示“Command not found”----处理方案
- 阿里云 esc 云服务器无缘无故的一次/usr/bin 目录丢失导致整个服务无法启动 # ./shutdown.sh ./shutdown.sh: line 41: dirname:command not found cannot find /catalina.sh the find /catalina.sh The file is absent or does not have execute
- automation - Jenkins pipline 执行 nodejs 命令时,提示 node: command not found
- $ npm install sh.exe": npm: command not found
- ./zkcli.sh: line 13: unzip: command not found
- CentOS7 crontab 不执行,报错 /bin/sh: root: command not found
- ./autogen.sh: line 44: libtoolize: command not found
- linux command Line and shell script bible(笔记四)
- linux command Line and shell script bible(笔记十)
- 在MAC上.sh command not found?
- MAC-nodejs与npm安装报错"-bash : npm: command not found"
- debian编译内核时err: line 65 dpkg-gencontrol command not found
- linux command Line and shell script bible(笔记十九)
- linux command Line and shell script bible(笔记十一)
- cygwin下执行makefile报/bin/sh: svn: command not found
- shell /bin/bash^M: bad interpreter错误和-bash: rz: command not found
- libtool: line 8986: gcc: command not found
- sudo执行提示Command not found
- shell脚本中字符串的常见操作及"command not found"报错处理(附源码)