Commits

Rodrigo Bistolfi committed fbaf1ba

installmedia: Added function for creating mountpoints

  • Participants
  • Parent commits 262e34c

Comments (0)

Files changed (1)

File vinstall/backend/installmedia.py

                 pass
             else:
                 raise e
-        partitions = media.Partition.all()
         cdroms = ( media.Partition(i) for i in media.list_cdroms() )
         partitions = media.Partition.all()
         #XXX refactor for DRY
     conf = "veclinux/VINSTALL.INI"
     config = ConfigParser.RawConfigParser()
     config.optionxform = str
+    print mnt,conf
     config.read(os.path.join(mnt,conf))
     return config
 
 
+def make_mountpoint(device):
+    """Create mountpoint for device
+
+    """
+    mountpoint = device.replace("/dev", "/mnt")
+    if not os.path.exists(mountpoint):
+        os.mkdir(mountpoint)
+
+
 def is_install_media(mnt):
     """ Checks for VINSTALL.INI the install config file added in 6.0