diff options
author | Navdeep Parhar <np@FreeBSD.org> | 2016-10-10 22:36:44 +0000 |
---|---|---|
committer | Navdeep Parhar <np@FreeBSD.org> | 2016-10-10 22:36:44 +0000 |
commit | eb46c98711f2f3f32ae564cc35bbdc3d2c28aeec (patch) | |
tree | 07d0c0aa928ee4b5d6ee692a59fb38e50dc606ab | |
parent | b422efa4c19f82f023acc1e901283a403fc6385c (diff) | |
download | src-eb46c98711f2f3f32ae564cc35bbdc3d2c28aeec.tar.gz src-eb46c98711f2f3f32ae564cc35bbdc3d2c28aeec.zip |
Add the ability to override the size of the swap partition when building
VM images. The default continues to be 1G.
Reviewed by: gjb@
Sponsored by: Chelsio Communications
Notes
Notes:
svn path=/head/; revision=307008
-rw-r--r-- | release/Makefile.vm | 1 | ||||
-rw-r--r-- | release/tools/vmimage.subr | 2 |
2 files changed, 2 insertions, 1 deletions
diff --git a/release/Makefile.vm b/release/Makefile.vm index 9de384650cbf..1c6a1936058b 100644 --- a/release/Makefile.vm +++ b/release/Makefile.vm @@ -8,6 +8,7 @@ VMTARGETS= vm-image VMFORMATS?= vhd vmdk qcow2 raw VMSIZE?= 20G +SWAPSIZE?= 1G VMBASE?= vm VHD_DESC= Azure, VirtualPC, Hyper-V, Xen disk image diff --git a/release/tools/vmimage.subr b/release/tools/vmimage.subr index b5a8bf7c6a53..14ef7f106e30 100644 --- a/release/tools/vmimage.subr +++ b/release/tools/vmimage.subr @@ -11,7 +11,7 @@ trap "cleanup" INT QUIT TRAP ABRT TERM write_partition_layout() { if [ -z "${NOSWAP}" ]; then - SWAPOPT="-p freebsd-swap/swapfs::1G" + SWAPOPT="-p freebsd-swap/swapfs::${SWAPSIZE}" fi _OBJDIR="$(make -C ${WORLDDIR} -V .OBJDIR)" |