Uploaded image for project: 'Jenkins'
  1. Jenkins
  2. JENKINS-45603

Jenkins pipeline shared library permission denied

XMLWordPrintable

      In my company we are facing the issue where a simple shared pipeline library that works with Jenkins version 2.46.3 fails with Jenkins 2.60.1 with the following stack trace:

       

      [Pipeline] library
      Loading library MMS-jenkins-shared-lib@master
       > /usr/bin/git rev-parse --is-inside-work-tree # timeout=10
      Setting origin to git@apdev10cmage001.dca.diginsite.net:PSTeam/MMS-jenkins-shared-lib.git
       > /usr/bin/git config remote.origin.url git@apdev10cmage001.dca.diginsite.net:PSTeam/MMS-jenkins-shared-lib.git # timeout=10
      Fetching origin...
      Fetching upstream changes from origin
       > /usr/bin/git --version # timeout=10
       > /usr/bin/git fetch --tags --progress origin +refs/heads/*:refs/remotes/origin/*
       > /usr/bin/git rev-parse master^\{commit} # timeout=10
       > /usr/bin/git rev-parse origin/master^\{commit} # timeout=10
      [Pipeline] }
      [Pipeline] // stage
      [Pipeline] }
      [Pipeline] // node
      [Pipeline] End of Pipeline
      java.io.IOException: Failed to mkdirs: BEN.M/shared-pipeline-scripted-test/workspace@libs/MMS-jenkins-shared-lib
       at hudson.FilePath.mkdirs(FilePath.java:1170)
       at hudson.plugins.git.GitSCM.createClient(GitSCM.java:742)
       at hudson.plugins.git.GitSCM.checkout(GitSCM.java:1104)
       at org.jenkinsci.plugins.workflow.steps.scm.SCMStep.checkout(SCMStep.java:109)
       at org.jenkinsci.plugins.workflow.libs.SCMSourceRetriever.doRetrieve(SCMSourceRetriever.java:108)
       at org.jenkinsci.plugins.workflow.libs.SCMSourceRetriever.retrieve(SCMSourceRetriever.java:84)
       at org.jenkinsci.plugins.workflow.libs.LibraryAdder.retrieve(LibraryAdder.java:150)
       at org.jenkinsci.plugins.workflow.libs.LibraryStep$Execution.run(LibraryStep.java:187)
       at org.jenkinsci.plugins.workflow.libs.LibraryStep$Execution.run(LibraryStep.java:139)
       at org.jenkinsci.plugins.workflow.steps.AbstractSynchronousNonBlockingStepExecution$1$1.call(AbstractSynchronousNonBlockingStepExecution.java:47)
       at hudson.security.ACL.impersonate(ACL.java:260)
       at org.jenkinsci.plugins.workflow.steps.AbstractSynchronousNonBlockingStepExecution$1.run(AbstractSynchronousNonBlockingStepExecution.java:44)
       at java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:511)
       at java.util.concurrent.FutureTask.run(FutureTask.java:266)
       at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1142)
       at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:617)
       at java.lang.Thread.run(Thread.java:748)
      Finished: FAILURE
      
      

       

       

      All systems are Linux Redhat 6 systems using regular virtual machines.

      The shared library plugin is in both cases version 2.7

       

      Could you please help me identify what is causing this issue? 

       

            Unassigned Unassigned
            nickapos Nick Apostolakis
            Votes:
            0 Vote for this issue
            Watchers:
            2 Start watching this issue

              Created:
              Updated:
              Resolved: