tmt/steps/provision/vagrant.py
def how(self):
        """ Decide what to do when HOW is ...
            does not add anything into Vagrantfile yet
        """
        self.debug()

        self.set_default('how', 'virtual')
        self.set_default('image', self.default_image)

        image = self.data['image']

        try:
            i = urlparse(image)
            if not i.schema:
                raise (i)
            self.image_uri = i
        except:
            pass

        self.debug('image_uri', self.image_uri)

        if self.image_uri:
            self.set_default('box', 'box_' + self.instance_name)

            if re.search(r"\.box$", image) is None:
                # an actual box file, Great!
                pass

            elif re.search(r"\.qcow2$", image) is None:
                # do some qcow2 magic
                self.data['box'] = '...'
                raise SpecificationError("NYI: QCOW2 image")

            else:
                raise SpecificationError(f"Image format not recognized: {image}")

        else:
            self.set_default('box', image)

        for x in ('how','box','image'):
            self.debug(x, self.data[x])

        # TODO: Dynamic call [switch] to specific how_*
        return True
 Decide what to do when HOW is ...
            does not add anything into Vagrantfile yet
        
Decide what to do when HOW is
does not add anything into Vagrantfile yet
Decide what to do when HOW is does not add anything into Vagrantfile yet
def how(self):
        self.debug()
        self.set_default('how', 'virtual')
        self.set_default('image', self.default_image)
        image = self.data['image']
        try:
            i = urlparse(image)
            if not i.schema:
                raise (i)
            self.image_uri = i
        except:
            pass
        self.debug('image_uri', self.image_uri)
        if self.image_uri:
            self.set_default('box', 'box_' + self.instance_name)
            if re.search(r"\.box$", image) is None:
                pass
            elif re.search(r"\.qcow2$", image) is None:
                self.data['box'] = '...'
                raise SpecificationError("NYI: QCOW2 image")
            else:
                raise SpecificationError(f"Image format not recognized: {image}")
        else:
            self.set_default('box', image)
        for x in ('how','box','image'):
            self.debug(x, self.data[x])
        return True
def how ( self ) : self . debug ( ) self . set_default ( 'how' , 'virtual' ) self . set_default ( 'image' , self . default_image ) image = self . data [ 'image' ] try : i = urlparse ( image ) if not i . schema : raise ( i ) self . image_uri = i except : pass self . debug ( 'image_uri' , self . image_uri ) if self . image_uri : self . set_default ( 'box' , 'box_' + self . instance_name ) if re . search ( r"\.box$" , image ) is None : pass elif re . search ( r"\.qcow2$" , image ) is None : self . data [ 'box' ] = '...' raise SpecificationError ( "NYI: QCOW2 image" ) else : raise SpecificationError ( f"Image format not recognized: {image}" ) else : self . set_default ( 'box' , image ) for x in ( 'how' , 'box' , 'image' ) : self . debug ( x , self . data [ x ] ) return True
Decide what to do when HOW is ...
does not add anything into Vagrantfile yet
Decide what to do when HOW is ... does not add anything into Vagrantfile yet
""" Decide what to do when HOW is ...
            does not add anything into Vagrantfile yet
        """ # an actual box file, Great! # do some qcow2 magic # TODO: Dynamic call [switch] to specific how_*
self