-
Bug
-
Resolution: Fixed
-
Major
- Jenkins 1.633
- credentials binding 1.5
- credentials 1.24
- workflow 1.10
steps to reproduce
- upload a zip file to credentials as a secret file give it an ID of "myzip"
- create a workflow that references the above secret file
node() { withCredentials([[$class: 'ZipFileBinding', credentialsId: 'myzip', variable: 'credentialsLocation']]) { sh 'THIS_SHOULD_FAIL_THE_BUILD' } }
- run the workflow
expected results
the workflow complets
actual results
the workflow fails with an exception removing the secret files (full stack in attached file)
java.io.IOException: remote file operation failed: /scratch/jenkins/secretFiles/ed503d92-4726-4033-9afe-00affd88bde6 at hudson.remoting.Channel@25888a1:c1617b93: java.nio.file.DirectoryNotEmptyException: /scratch/jenkins/secretFiles/ed503d92-4726-4033-9afe-00affd88bde6/credentials.zip at hudson.FilePath.act(FilePath.java:985) at hudson.FilePath.act(FilePath.java:967) at hudson.FilePath.deleteRecursive(FilePath.java:1169) at org.jenkinsci.plugins.credentialsbinding.impl.FileBinding$UnbinderImpl.unbind(FileBinding.java:76) at org.jenkinsci.plugins.credentialsbinding.impl.BindingStep$Callback.cleanup(BindingStep.java:176) at org.jenkinsci.plugins.credentialsbinding.impl.BindingStep$Callback.onFailure(BindingStep.java:189) at org.jenkinsci.plugins.workflow.cps.CpsBodyExecution$FailureAdapter.receive(CpsBodyExecution.java:294) at com.cloudbees.groovy.cps.impl.ThrowBlock$1.receive(ThrowBlock.java:68) Caused by: java.nio.file.DirectoryNotEmptyException: /scratch/jenkins/secretFiles/ed503d92-4726-4033-9afe-00affd88bde6/credentials.zip at sun.nio.fs.UnixFileSystemProvider.implDelete(UnixFileSystemProvider.java:242) at sun.nio.fs.AbstractFileSystemProvider.delete(AbstractFileSystemProvider.java:103) at java.nio.file.Files.delete(Files.java:1079)
- is blocking
-
JENKINS-29255 Use of RSA private key yields error: Permissions 0644 for '/…/secretFiles/…/blah.id_rsa' are too open
- Resolved
- links to