def mac_install(self): log.info("Downloading virtualbox") self.init_progres_bar("Downloading virtualbox...") # start download path_to_vbox_distr = Dl.get(url=self.config["vbox_download"], dest_path=path.expandvars( self.config["downloads_path"]), on_update=self.update_progres_bar, abort=self.abort) self.finalize_progres_bar() self.message("Download completed. Mounting...") log.info("Installing virtualbox") if self.abort.is_set(): log.debug("Vbox intallation aborted.") return self.on_configuration_in_progress(True) self.mount_vbox_distro(path_to_vbox_distr) # OS SPECIFIC!!! if self.update: self.uninstall_vbox() self.message("Virtualbox old version is uninstalled") self.message("Mounted") self.message("Installing Virtualbox") self._install_vbox_dar_win(path_to_vbox_distr) self.message("Installed. Unmounting vbox distro") self.unmount_vbox_distro(self.config["vbox_distro_mountpoint"]) self.message("Unmounted. Removing distro") self.delete_vbox_distro(path_to_vbox_distr) self.message("Distro removed.") self.complete(True, "")
def _linux_install_download(self): log.debug("Downloading virtualbox") self.init_progres_bar("Downloading virtualbox...") self.path_to_vbox_distr = Dl.get(url=self.config["vbox_download"], dest_path=get_full_path( self.config["downloads_path"]), on_update=self.update_progres_bar, abort=self.abort) self.finalize_progres_bar() self.message("Download completed. Installing...")
def win_install(self): self.init_progres_bar("Downloading virtualbox...") # start download path_to_vbox_distr = Dl.get(url=self.config["vbox_download"], dest_path=path.expandvars( self.config["downloads_path"]), on_update=self.update_progres_bar, abort=self.abort) self.finalize_progres_bar() self.message("Download completed. Installing...") self.on_configuration_in_progress(True) self._install_vbox_windows(path_to_vbox_distr) self.message("Instalation complete!") self.complete(True, "")
def test_download(self): r = dl.get( "https://sourceforge.net/projects/islands-image/files/Islands_vm_v0.0.011.ova/download", path.expandvars("%USERPROFILE%\\Downloads\\")) print(r)
def test_download(self): link = self.config['vbox_download'] Downloader.get(link)