diff --git a/boxes/debian/download b/boxes/debian/download index 43e5b94..fd6f95a 100755 --- a/boxes/debian/download +++ b/boxes/debian/download @@ -1,7 +1,5 @@ #!/bin/bash -# -*- mode:shell-mode;tab-width:2;indent-tabs-mode:nil;coding:utf-8 -*- -# vim: ft=shell syn=shell fileencoding=utf-8 sw=2 ts=2 ai eol et si -# + # This is the code extracted from /usr/share/lxc/templates/lxc-debian # that comes with Ubuntu 12.10 which is responsible for downloading the # rootfs files / packages @@ -27,7 +25,7 @@ write_sourceslist() rootfs=$1 arch=$2 release=$3 - + MIRROR=${MIRROR:-http://ftp.debian.org/debian} SECURITY_MIRROR=${SECURITY_MIRROR:-http://security.debian.org/debian-security} @@ -64,7 +62,7 @@ download_debian() cache=$1 arch=$2 release=$3 - + packages=\ sudo,\ ifupdown,\ @@ -97,7 +95,7 @@ ca-certificates fi echo "installing packages: ${packages}" - + trap cleanup EXIT SIGHUP SIGINT SIGTERM # check the mini debian was not already downloaded partial=${cache}/partial-${release}-${arch} @@ -106,7 +104,7 @@ ca-certificates echo "Failed to create '${partial}' directory" return 1 fi - + # download a mini debian into a cache echo "Downloading debian ${release} minimal ..." debootstrap \ @@ -115,7 +113,7 @@ ca-certificates --components=main,contrib,non-free \ --arch=${arch} \ --include=${packages} ${release} ${partial} ${MIRROR} - + if [ $? -ne 0 ]; then echo 'Failed to download the rootfs, aborting.' return 1 diff --git a/boxes/debian/lxc-template b/boxes/debian/lxc-template index ab5cab3..2168760 100755 --- a/boxes/debian/lxc-template +++ b/boxes/debian/lxc-template @@ -1,6 +1,4 @@ #!/bin/bash -# -*- mode:shell-mode;tab-width:2;indent-tabs-mode:nil;coding:utf-8 -*- -# vim: ft=shell syn=shell fileencoding=utf-8 sw=2 ts=2 ai eol et si # This is a modified version of /usr/share/lxc/templates/lxc-debian # that comes with Ubuntu 12.10 changed to suit vagrant-lxc needs @@ -139,7 +137,7 @@ EOF chroot $rootfs /usr/sbin/update-rc.d -f $service remove > /dev/null 2>&1 echo "service ${service} removed from init" done - + # suppress log level output for udev #sed -i "s/=\"err\"/=0/" $rootfs/etc/udev/udev.conf @@ -276,7 +274,7 @@ lxc.cgroup.memory.limit_in_bytes = 1024M # CPUs # assign first CPU to this container: -#lxc.cgroup.cpuset.cpus = 0 +#lxc.cgroup.cpuset.cpus = 0 # assign the first, the second and the last CPU #lxc.cgroup.cpuset.cpus = 0-1,3 # assign the first and the last CPU