Avoid vagrant user creation on quantal64 base box in case it has already been created

This commit is contained in:
Fabio Rehm 2013-03-30 16:44:31 -03:00
parent b54dcdc57b
commit fcaf98d669

View file

@ -78,8 +78,10 @@ EOF
rm -f $rootfs/etc/init/tty{5,6}.conf rm -f $rootfs/etc/init/tty{5,6}.conf
fi fi
if ! (grep -q vagrant $rootfs/etc/passwd); then
chroot $rootfs useradd --create-home -s /bin/bash vagrant chroot $rootfs useradd --create-home -s /bin/bash vagrant
echo "vagrant:vagrant" | chroot $rootfs chpasswd echo "vagrant:vagrant" | chroot $rootfs chpasswd
fi
return 0 return 0
} }