aboutsummaryrefslogtreecommitdiff
path: root/kvmx-create
diff options
context:
space:
mode:
authorSilvio Rhatto <rhatto@riseup.net>2018-06-23 09:53:54 -0300
committerSilvio Rhatto <rhatto@riseup.net>2018-06-23 09:53:54 -0300
commitc94472dc0e24d234eb8e135cfcc4029018072dc3 (patch)
tree7f0f25257e4da4d5c82ea1c74f98a41fea81153e /kvmx-create
parent23e5ab8db41d37ae70a226fc5446dc9ba51a26bc (diff)
downloadkvmx-c94472dc0e24d234eb8e135cfcc4029018072dc3.tar.gz
kvmx-c94472dc0e24d234eb8e135cfcc4029018072dc3.tar.bz2
Check for requirements and use spicy as default spice_client
Diffstat (limited to 'kvmx-create')
-rwxr-xr-xkvmx-create16
1 files changed, 10 insertions, 6 deletions
diff --git a/kvmx-create b/kvmx-create
index 9d956ab..64a66ec 100755
--- a/kvmx-create
+++ b/kvmx-create
@@ -197,6 +197,16 @@ function kvmx_create_vmdebootstrap {
# Custom version
#
function kvmx_create_custom {
+ # Check dependencies
+ DEPENDENCIES="sudo apt qemu-img sed awk tr head debootstrap chroot"
+ __kvmx_check_dependencies
+
+ # Check for package requirements
+ #for req in debootstrap parted apt-transport-https; do
+ for req in debootstrap parted; do
+ kvmx_install_package $req
+ done
+
if [ -z "$TMP" ]; then
TMP="/tmp"
fi
@@ -231,12 +241,6 @@ function kvmx_create_custom {
fi
fi
- # Check for requirements.
- #for req in debootstrap parted apt-transport-https; do
- for req in debootstrap parted; do
- kvmx_install_package $req
- done
-
if [ -z "$image_type" ] || [ "$image_type" == "file" ]; then
echo "Creating image file..."
#kvmx_sudo_run dd if=/dev/zero of=$image bs=$size count=1