首页 > 解决方案 > 詹金斯+没有这样的财产:npm for class:groovy.lang.Binding

问题描述

我在詹金斯管道中有以下代码

  stage("Install Dependencies") {
    configFileProvider([configFile(fileId: "test.npmrepo.readonly", targetLocation: "${WORKSPACE}/.npmrepo")]){}
     withEnv(["HOME=."]){
      script {
        sh “npm ci”
        sh "git checkout -- .npmrepo"
      }
    }   }

如屏幕截图所示,我收到错误消息,我猜问题出在“npm ci”,请告知

Jenkins 控制台中的错误:

在此处输入图像描述

标签: jenkinsnpmjenkins-pipelinenpm-installjenkins-groovy

解决方案



推荐阅读