Repository: google/docker-explorer

Issue:
overlay mount error: mount: special device overlay does not exist
> de.py mount 6f51d96cdd2c /root/docker/docker-explorer/mnt
/bin/mount -t overlay overlay -o ro,lowerdir="/var/lib/docker/overlay2/44bbbf57e9be5c160d9addac59b51a83c35d90955b4179ca4d893ae2942ef8e1/diff:/var/lib/docker/overlay2/l/F74KTIZFM3OJPZ44L4Y5OMLQRY:/var/lib/docker/overlay2/l/MULY352PDKNLWPYT22DFGHCJXA:/var/lib/docker/overlay2/l/ZH325HA5PVVFXEPQCWG6VTKIZ3:/var/lib/docker/overlay2/l/HFQVPV3GII75YHNJBJAJBMOMIZ:/var/lib/docker/overlay2/l/BXKFWQ4WPHOZMZHHD6TFT3ITZ7:/var/lib/docker/overlay2/l/KABGVLKHDM2RBUJKGPGWN3X7RU" /root/docker/docker-explorer/mnt
Do you want to mount this container ID: 6f51d96cdd2cff0601c5922917d4a62e593917cd5358d710a344111db1c1e354 on /root/docker/docker-explorer/mnt ?
(ie: run these commands) [Y/n]
Y
**mount: special device overlay does not exist**


OS: CentOS 7.5.1804
Kernel:  3.10.0-862.14.4.el7.x86_64
Docker: 1.13.1

> docker ps
CONTAINER ID        IMAGE               COMMAND                  CREATED             STATUS              PORTS                  NAMES
6f51d96cdd2c        atmoz/sftp          "/entrypoint foo:p..."   4 days ago          Up 4 days           0.0.0.0:4444->22/tcp   sftp


Discussion:
codecov-io: # [Codecov](https://codecov.io/gh/google/docker-explorer/pull/64?src=pr&el=h1) Report
> Merging [#64](https://codecov.io/gh/google/docker-explorer/pull/64?src=pr&el=desc) into [master](https://codecov.io/gh/google/docker-explorer/commit/e6612da9a4db2fb79711343712350099185de098?src=pr&el=desc) will **not change** coverage.
> The diff coverage is `n/a`.

[![Impacted file tree graph](https://codecov.io/gh/google/docker-explorer/pull/64/graphs/tree.svg?width=650&token=lmhUb8WnfJ&height=150&src=pr)](https://codecov.io/gh/google/docker-explorer/pull/64?src=pr&el=tree)

```diff
@@           Coverage Diff           @@
##           master      #64   +/-   ##
=======================================
  Coverage   90.93%   90.93%           
=======================================
  Files           7        7           
  Lines         695      695           
=======================================
  Hits          632      632           
  Misses         63       63
```


| [Impacted Files](https://codecov.io/gh/google/docker-explorer/pull/64?src=pr&el=tree) | Coverage Δ | |
|---|---|---|
| [tests.py](https://codecov.io/gh/google/docker-explorer/pull/64/diff?src=pr&el=tree#diff-dGVzdHMucHk=) | `100% <ø> (ø)` | :arrow_up: |
| [docker\_explorer/storage.py](https://codecov.io/gh/google/docker-explorer/pull/64/diff?src=pr&el=tree#diff-ZG9ja2VyX2V4cGxvcmVyL3N0b3JhZ2UucHk=) | `88.76% <ø> (ø)` | :arrow_up: |

------

[Continue to review full report at Codecov](https://codecov.io/gh/google/docker-explorer/pull/64?src=pr&el=continue).
> **Legend** - [Click here to learn more](https://docs.codecov.io/docs/codecov-delta)
> `Δ = absolute <relative> (impact)`, `ø = not affected`, `? = missing data`
> Powered by [Codecov](https://codecov.io/gh/google/docker-explorer/pull/64?src=pr&el=footer). Last update [e6612da...a3da804](https://codecov.io/gh/google/docker-explorer/pull/64?src=pr&el=lastupdated). Read the [comment docs](https://docs.codecov.io/docs/pull-request-comments).


Patch:
diff --git a/docker_explorer/storage.py b/docker_explorer/storage.py
index 390a212..9e84a68 100644
--- a/docker_explorer/storage.py
+++ b/docker_explorer/storage.py
@@ -211,7 +211,7 @@ class OverlayStorage(BaseStorage):
 
     cmd = [
         '/bin/mount', '-t', 'overlay', 'overlay', '-o',
-        'ro,lowerdir="{0:s}:{1:s}"'.format(upper_dir, lower_dir), mount_dir]
+        'ro,lowerdir={0:s}:{1:s}'.format(upper_dir, lower_dir), mount_dir]
     return [cmd]
 
 


Test patch:
diff --git a/tests.py b/tests.py
index 0b3a425..952778e 100644
--- a/tests.py
+++ b/tests.py
@@ -547,10 +547,10 @@ class TestOverlayStorage(DockerTestCase):
     commands = [' '.join(cmd) for cmd in commands]
     expected_commands = [(
         '/bin/mount -t overlay overlay -o ro,lowerdir='
-        '"test_data/docker/overlay/974e2b994f9db74e1ddd6fc546843bc65920e786612'
+        'test_data/docker/overlay/974e2b994f9db74e1ddd6fc546843bc65920e786612'
         'a388f25685acf84b3fed1/upper:'
         'test_data/docker/overlay/a94d714512251b0d8a9bfaacb832e0c6cb70f71cb71'
-        '976cca7a528a429336aae/root" '
+        '976cca7a528a429336aae/root '
         '/mnt')]
     self.assertEqual(expected_commands, commands)
 
@@ -704,10 +704,10 @@ class TestOverlay2Storage(DockerTestCase):
     commands = [' '.join(cmd) for cmd in commands]
     expected_commands = [(
         '/bin/mount -t overlay overlay -o ro,lowerdir='
-        '"test_data/docker/overlay2/'
+        'test_data/docker/overlay2/'
         '92fd3b3e7d6101bb701743c9518c45b0d036b898c8a3d7cae84e1a06e6829b53/diff:'
         'test_data/docker/overlay2/l/OTFSLJCXWCECIG6FVNGRTWUZ7D:'
-        'test_data/docker/overlay2/l/CH5A7XWSBP2DUPV7V47B7DOOGY" /mnt'
+        'test_data/docker/overlay2/l/CH5A7XWSBP2DUPV7V47B7DOOGY /mnt'
         )]
     self.assertEqual(expected_commands, commands)