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

file attributes are not preserved by copying

      the ownership of files copied from master to slave changes to read only (and write right for user) even if they were executable before which is quite awkward when scripts are to be used

          [JENKINS-8249] file attributes are not preserved by copying

          Romain Seguy added a comment -

          The issue comes from Ant's copy task which doesn't preserve permissions:

          Unix Note: File permissions are not retained when files are copied; they end up with the default UMASK permissions instead. This is caused by the lack of any means to query or set file permissions in the current Java runtimes. If you need a permission-preserving copy function, use <exec executable="cp" ... > instead.

          So I can't fix that unless fully rewriting Hudson's FilePath copy mechanism, which is nearly not possible (everything is, but the amount of time would be huge).

          Romain Seguy added a comment - The issue comes from Ant's copy task which doesn't preserve permissions: Unix Note: File permissions are not retained when files are copied; they end up with the default UMASK permissions instead. This is caused by the lack of any means to query or set file permissions in the current Java runtimes. If you need a permission-preserving copy function, use <exec executable="cp" ... > instead. So I can't fix that unless fully rewriting Hudson's FilePath copy mechanism, which is nearly not possible (everything is, but the amount of time would be huge).

          Romain Seguy added a comment -

          I need to take a look at JENKINS-9397 to see if this can be a good basis for this ER.

          Romain Seguy added a comment - I need to take a look at JENKINS-9397 to see if this can be a good basis for this ER.

            danielpetisme Daniel Petisme
            hbockelmann hbockelmann
            Votes:
            0 Vote for this issue
            Watchers:
            3 Start watching this issue

              Created:
              Updated: