]> git.apps.os.sepia.ceph.com Git - ceph.git/commitdiff
tasks/ceph_fuse: populate ctx.mounts earlier
authorJohn Spray <jspray@redhat.com>
Tue, 24 Feb 2015 09:26:10 +0000 (09:26 +0000)
committerJohn Spray <jspray@redhat.com>
Tue, 14 Apr 2015 13:13:39 +0000 (14:13 +0100)
...so that if an error happens during mount, I can
use the interactive console to access ctx.mounts.

Signed-off-by: John Spray <john.spray@redhat.com>
tasks/ceph_fuse.py

index c2c1a535b5c8032e311cd63f44e060d81cf5b0e9..60988dd1fdc6beb77274359dd4e45271c2ecc632 100644 (file)
@@ -109,6 +109,8 @@ def task(ctx, config):
         if client_config.get('mounted', True):
             mounted_by_me[id_] = all_mounts[id_]
 
+    ctx.mounts = all_mounts
+
     # Mount any clients we have been asked to (default to mount all)
     for mount in mounted_by_me.values():
         mount.mount()
@@ -122,7 +124,6 @@ def task(ctx, config):
         if mount.is_mounted():
             mount.umount_wait()
 
-    ctx.mounts = all_mounts
     try:
         yield all_mounts
     finally: