jekins发布时报错

环境说明

主要是jekins发布前端项目,但是暂时不支持node环境,因此使用了java套壳的方式,引用一些maven插件,进行对前端项目进行打包

错误信息

Failed to execute goal com.github.eirslett:frontend-maven-plugin:1.6:install-node-and-npm (install node and npm) on project *project-name-web*: Could not extract the Node archive: Could not extract archive: '/root/.m2/repository/com/github/eirslett/node/12.3.1/node-12.3.1-linux-x64.tar.gz': EOFException -> [Help 1]

还同时产生了以下问题

[ERROR] Failed to execute goal org.apache.maven.plugins:maven-release-plugin:2.5.3:prepare (default-cli) on project *project-name-web*: Maven execution failed, exit code: '1' -> [Help 1]
[ERROR] 
[ERROR] To see the full stack trace of the errors, re-run Maven with the -e switch.
[ERROR] Re-run Maven using the -X switch to enable full debug logging.
[ERROR] 
[ERROR] For more information about the errors and possible solutions, please read the following articles:

这个命令最终通过各种实验发现属于node版本问题,感觉非常郁闷,因为在pom文件中,我使用了以下属性,那么不应该从指定镜像下载么?怎么会存在本地可以下载,jekins环境里无法下载的情况呢,经测试确实属于node版本该问题

https://npm.taobao.org/mirrors/node/
 https://npm.taobao.org/mirrors/npm/

解决方案

使用了一个别人使用过的node版本就正常了

你可能感兴趣的:(前端模块开发,jenkins)