[SOLVED] Permissions/ownership removed when moving files on shared volumes

Expected behavior

Moving of files from one folder to another should preserve permissions and ownership

Actual behaviour

Permissions and ownership is lost completely making the file unusable

Information

pinata diagnose -u:

OS X: version 10.11.1 (build: 15B42)
Docker.app: version v1.11.1-beta12
Running diagnostic tests:
[OK] Moby booted
[OK] driver.amd64-linux
[OK] vmnetd
[OK] osxfs
[OK] db
[OK] slirp
[OK] menubar
[OK] environment
[OK] Docker
[OK] VT-x
Most specific failure is: No error was detected

Steps to reproduce the behavior

  • docker pull centos
  • docker run -t -i -v /Users/byronsmith/Documents/data:/data:rw centos /bin/bash
  • mkdir -p foo/bar
  • touch foo/bar/file
  • ls -lan foo/bar/file

-rw-r–r-- 1 0 0 0 May 23 05:42 foo/bar/file

  • mv foo/bar/ .
  • ls -lan

drwxr-xr-x 3 0 0 102 May 23 05:42 bar
drwxr-xr-x 2 0 0 68 May 23 05:43 foo

  • ls -lan bar/

-??? ? ? ? ? ? file

File now is impossible to chmod or chown.

I have a previous post relating to this but I’ve simplified the issue hoping to make it easier for the docker team to have a look. Also, I don’t know how to remove my other post.

1 Like

New 1.11.1-beta13 has resolved this issue. Thank you