我使用的是Jenkins管道,但自从上次更新以来,它在tools期间失败,并显示以下错误:"ERROR: No jenkins.plugins.nodejs.tools.NodeJSInstallation named 12.5.0“。 这是针对Jenkins 2.183和NodeJS-plugin1.33的 // When using a constant string, it works.
pipeline {
agent any
environment {
NODEJS_VERSION = readFile '.nvmrc'
}
tool
目前,我使用的是Jenkins管道脚本。 为了运行我的测试,我需要访问桌面上的代码。 我试过这个: pipeline {
agent any
tools {nodejs "node"}
stages {
stage('Tests') {
steps {
sh 'cd users/tests/'
sh 'npm run shopfloor.shopfloor'
}
}
}
} 如何切换到我的测试文件夹,然后运行"npm run te
我在Jenkins中使用Kubernetes Cloud服务器运行管道时出错。
在我得到Cannot contact nodejs-rn5f3: hudson.remoting.ChannelClosedException: Channel "hudson.remoting.Channel@3b1e0041:nodejs-rn5f3": Remote call on nodejs-rn5f3 failed. The channel is closing down or has closed down的npm install之前,一切都很正常
如何修复此错误?
以下是我的日志:
帮助我解决以下的angular构建问题
ng build --configuration=qa
/opt/tomcat/.jenkins/tools/jenkins.plugins.nodejs.tools.NodeJSInstallation/NodeJS_14.15.0/lib/node_modules/@angular/cli/utilities/color.js:22
const colors = ansiColors.create();
^
TypeError: ansiColors.create is not a function
我将Jenkins作为一个码头容器运行,并已安装了,并完全按照设置说明执行。当我尝试使用node运行脚本时,我会得到以下错误:
/tmp/jenkins9123978873441132802.sh: line 1: node: not found
Build step 'Execute shell' marked build as failure
Finished: FAILURE
我检查了坞卷,node bin是它应该在的地方,并且是可执行的,当我从我的主机服务器运行它时,它工作得很好:
user@server:/data/jenkins/tools/jenkins.plug
当使用NodeJS插件在Jenkins Groovy管道中执行"npm install“时,我遇到了一个令人沮丧的问题,该过程挂起并显示以下错误:
npm install --ddd ng-cli
npm info it worked if it ends with ok
npm verb cli [ '/var/jenkins_home/tools/jenkins.plugins.nodejs.tools.NodeJSInstallation/nodejs893-v2/bin/node',
npm verb cli '/var/jenkins_home/t
我在Jenkinsfile中遇到了Jenkins管道的问题。我在Jenkins实例上有4个不同的nodeJs版本。我想选择在我的管道中使用哪一个插件,但是官方插件示例()根本不起作用。
我尝试了第一种方法,但失败了,因为$PATH被tools部分覆盖。
pipeline {
agent any
tools {
// I hoped it would work with this command...
nodejs 'nodejs6'
}
stages {
stage('Example') {
有了Jenkins Docker镜像,我想将完整的'npm‘环境添加到该镜像中。因此,在构建Dockerfile之后,我有了一个同时具有Jenkins和'npm‘环境的映像。
其目的是让Jenkins作业运行shell命令'npm‘。所以'npm‘应该在$PATH上(在Ubuntu中)。
我已经有了一个Dockerfile,里面有很多东西,比如Jenkins和Maven。
用描述了节点的一种解决方案。重要的是,我能做些类似的事情吗?我应该将哪些文件夹复制到Jenkins docker镜像?
FROM node as nodejs
FROM jenkins/je
我已经安装了Jenkins,增加了我的回购,也安装了NodeJS插件。但是在>将Node & npm /文件夹提供给我有空下拉列表的路径。
(使用教程)作为结果,Jenkins与
ERROR: Build step failed with exception
java.lang.IllegalArgumentException: NodeJS Installation not found :
at jenkins.plugins.nodejs.NodeJSPlugin.findInstallationByName(NodeJSPlugin.java:42)
a