mirror of
https://github.com/kevingruesser/bootstrap-vz.git
synced 2025-08-22 09:50:37 +00:00
Update volume image path after move it
The `loopback.MoveImage` task wasn't updating `info.volume.image_path` after moving the volume image file. That made `volume.Delete` to fail when called, because it would try to remove a file that didn't exist anymore.
This commit is contained in:
parent
9c0a0ade08
commit
aa1f8cf189
1 changed files with 1 additions and 0 deletions
|
@ -45,6 +45,7 @@ class MoveImage(Task):
|
|||
destination = os.path.join(info.manifest.bootstrapper['workspace'], filename)
|
||||
import shutil
|
||||
shutil.move(info.volume.image_path, destination)
|
||||
info.volume.image_path = destination
|
||||
import logging
|
||||
log = logging.getLogger(__name__)
|
||||
log.info('The volume image has been moved to ' + destination)
|
||||
|
|
Loading…
Add table
Reference in a new issue