For test purposes it is useful to bootstrap tails using virtual machines and files. Here is how it can be done with KVM.
$ wget 'https://tails-dl.urown.net/tails/stable/tails-amd64-3.0/tails-amd64-3.0.iso' $ qemu-img create -f raw tails-installed.img 4G $ kvm -m 4096 -cdrom tails-amd64-3.0.iso -device piix3-usb-uhci \ -boot d \ -drive id=my_usb_disk,file=tails-installed.img,if=none,format=raw \ -device usb-storage,drive=my_usb_disk,removable=on \ -net nic -net user -display sdl
From the virtual machine console, install tails to the USB device (i.e. tails-installed.img). When the installation is complete Control-C KVM. Copy tails-installed.img to tails-backup.img in case you want to start over. Run tails with:
kvm -m 4096 -device piix3-usb-uhci \ -drive id=my_usb_disk,file=tails-installed.img,if=none,format=raw \ -device usb-storage,drive=my_usb_disk,removable=on \ -net nic -net user -display sdl
I tried to do the same using VirtualBox because it is the preferred virtualization mechanism of SecureDrop but it failed because the USB device is not identified as a removable device, i.e. the equivalent of removable=on in KVM does not seem to exist with VirtualBox. Also I discovered that USB is only fully supported via proprietary extensions to VirtualBox and this is not something I’m willing to use.