File tree Expand file tree Collapse file tree 6 files changed +27
-6
lines changed
Expand file tree Collapse file tree 6 files changed +27
-6
lines changed Original file line number Diff line number Diff line change @@ -17,6 +17,10 @@ Vagrant.configure("2") do |config|
1717 config . vm . box = "debian/#{ release } 64"
1818 config . vm . box_check_update = true
1919 config . vm . hostname = "ncp-vm"
20+ config . vm . define "ncp-vm"
21+ config . vm . provider :libvirt do |libvirt |
22+ libvirt . default_prefix = ""
23+ end
2024
2125 config . vm . synced_folder '.' , '/vagrant' , disabled : true
2226
@@ -39,6 +43,7 @@ Vagrant.configure("2") do |config|
3943 run_app_unsafe post-inst.sh
4044 cd /
4145 rm -r /tmp/nextcloudpi
46+ echo "root:ownyourbits" | chpasswd
4247 systemctl disable sshd
4348 poweroff
4449 SHELL
Original file line number Diff line number Diff line change @@ -35,10 +35,14 @@ build/build-LXD.sh
3535# Docker x86
3636build/build-docker.sh x86
3737
38+ # VM
39+ build/build-VM.sh
40+
3841# Tests
3942[[ " ${SKIP_TESTS} " != 1 ]] && {
4043 test_lxc
4144 test_docker
45+ test_vm
4246}
4347
4448# Docker other
@@ -60,9 +64,6 @@ build/build-SD-armbian.sh odroidc4 OdroidC4
6064build/build-SD-armbian.sh odroidc2 OdroidC2
6165# build/build-SD-armbian.sh orangepizeroplus2-h5 OrangePiZeroPlus2
6266
63- # VM
64- build/build-VM.sh
65-
6667# Uploads
6768[[ " $FTPPASS " == " " ]] && exit
6869upload_docker
Original file line number Diff line number Diff line change @@ -18,7 +18,7 @@ SIZE=3G # Raspbian image size
1818# CLEAN=0 # Pass this envvar to skip cleaning download cache
1919IMG=" NextCloudPi_VM_$( date " +%m-%d-%y" ) .img"
2020IMG=tmp/" $IMG "
21- VM=" /var/lib/libvirt/images/nextcloudpi_default .img"
21+ VM=" /var/lib/libvirt/images/ncp-vm .img"
2222
2323TAR=output/" $( basename " $IMG " .img ) .tar.bz2"
2424
Original file line number Diff line number Diff line change @@ -461,6 +461,21 @@ function test_lxc()
461461 lxc stop ncp
462462}
463463
464+ function test_vm()
465+ {
466+ local ip
467+ virsh --connect qemu:///system shutdown ncp-vm & > /dev/null || true
468+ virsh --connect qemu:///system start ncp-vm
469+ while [[ " ${ip} " == " " ]]; do
470+ ip=" $( virsh --connect qemu:///system domifaddr ncp-vm | grep ipv4 | awk ' { print $4 }' | sed ' s|/24||' ) "
471+ sleep 0.5
472+ done
473+ tests/activation_tests.py " ${ip} "
474+ tests/nextcloud_tests.py " ${ip} "
475+ # tests/system_tests.py
476+ virsh --connect qemu:///system shutdown ncp-vm
477+ }
478+
464479# License
465480#
466481# This script is free software; you can redistribute it and/or modify it
Original file line number Diff line number Diff line change 11version : ' 3'
22services :
33 nextcloudpi-dev :
4- image : ownyourbits/nextcloudpi-x86
4+ image : ownyourbits/nextcloudpi
55 command : " ${IP}"
66 ports :
77 - " 80:80"
Original file line number Diff line number Diff line change 11version : ' 3'
22services :
33 nextcloudpi :
4- image : ownyourbits/nextcloudpi-x86
4+ image : ownyourbits/nextcloudpi
55 command : " ${IP}"
66 ports :
77 - " 80:80"
You can’t perform that action at this time.
0 commit comments