summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--[-rwxr-xr-x]mic/imager/loop.py6
1 files changed, 4 insertions, 2 deletions
diff --git a/mic/imager/loop.py b/mic/imager/loop.py
index 268ba84..04abd0a 100755..100644
--- a/mic/imager/loop.py
+++ b/mic/imager/loop.py
@@ -160,6 +160,7 @@ class LoopImageCreator(BaseImageCreator):
'name': imgname,
'size': part.size or 4096L * 1024 * 1024,
'fstype': part.fstype or 'ext3',
+ 'fsopts': part.fsopts or None,
'aft_fstype': aft_fstype or None,
'extopts': part.extopts or None,
'vdfsopts': part.vdfsopts or None,
@@ -336,7 +337,6 @@ class LoopImageCreator(BaseImageCreator):
# Actual implementation
#
def _mount_instroot(self, base_on=None):
-
if base_on and os.path.isfile(base_on):
self._imgdir = os.path.dirname(base_on)
imgname = os.path.basename(base_on)
@@ -361,6 +361,7 @@ class LoopImageCreator(BaseImageCreator):
for loop in self._instloops:
fstype = loop['fstype']
+ fsopt = loop['fsopts']
mp = os.path.join(self._instroot, loop['mountpoint'].lstrip('/'))
size = loop['size'] * 1024L * 1024L
imgname = loop['name']
@@ -381,6 +382,7 @@ class LoopImageCreator(BaseImageCreator):
fstype,
self._blocksize,
loop['label'],
+ fsopt,
fsuuid = loop['uuid'])
if fstype in ("ext2", "ext3", "ext4"):
@@ -389,7 +391,7 @@ class LoopImageCreator(BaseImageCreator):
try:
msger.verbose('Mounting image "%s" on "%s"' % (imgname, mp))
fs.makedirs(mp)
- loop['loop'].mount(init_expand=loop['init_expand'])
+ loop['loop'].mount(fsopt, init_expand=loop['init_expand'])
# Make an autogenerated uuid avaialble in _get_post_scripts_env()
if loop['kspart'] and loop['kspart'].uuid is None and \
loop['loop'].uuid: