Пример #1
0
 def get_cl_assemble_path(self):
     fromEnv = self._getFromEnv('cl_assemble_path')
     if fromEnv:
         return fromEnv
     rootDev = self.Get('os_assemble_root_dev')
     if rootDev:
         mp = isMount(rootDev)
         if mp:
             return mp
     pathBuilder = path.join("/mnt",
                     self.Get('os_assemble_system_profile').rpartition(
                     '/profiles/')[2].replace("/","-"))
     if path.exists(pathBuilder):
         try:
             os.rmdir(pathBuilder)
         except:
             pass
     return pathBuilder
Пример #2
0
 def get_os_scratch(self):
     """Current system is scratch"""
     if self.Get('os_root_type') == 'livecd':
         return "on" if isMount('/mnt/scratch/workspace') else "off"
     else:
         return "on" if isMount('/mnt/scratch') else "off"