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

Jenkins cannot delete root-owned files/folders in jenkins-owned directories

    XMLWordPrintable

Details

    • Improvement
    • Resolution: Unresolved
    • Minor
    • core

    Description

      We want to be able to wipe workspaces containing files created via Docker containers (and thus owned by root). In a shell, as jenkins, we can delete root-owned files/folders as long as they are within jenkins-owned directories. But this function ( https://github.com/jenkinsci/jenkins/blob/6c2fffb/core/src/main/java/hudson/Util.java#L299 ) fails in that case.

      Perhaps, it's due to a windowsOS java limitation which cannot delete a non-empty directory?

      Could it be possible to create a special implementation for unix, that allows deletion of non-empty directories and thus supports the use-case mentioned above?

      Attachments

        Issue Links

          Activity

            People

              Unassigned Unassigned
              pdupont Philippe Dupont
              Votes:
              11 Vote for this issue
              Watchers:
              20 Start watching this issue

              Dates

                Created:
                Updated: