aboutsummaryrefslogtreecommitdiff
path: root/share/hydractl/provision-chroot
diff options
context:
space:
mode:
authorSilvio Rhatto <rhatto@riseup.net>2017-06-28 10:44:50 -0300
committerSilvio Rhatto <rhatto@riseup.net>2017-06-28 10:44:50 -0300
commita3a472298878996dc00273e58efcbfcdf53039fd (patch)
treef6cba54fd43e3c588d7d825519348e14cde10fff /share/hydractl/provision-chroot
parent83c155d81de0666bfc0e05772139569ae42d7c1f (diff)
downloadhydra-a3a472298878996dc00273e58efcbfcdf53039fd.tar.gz
hydra-a3a472298878996dc00273e58efcbfcdf53039fd.tar.bz2
Apt config at provision
Diffstat (limited to 'share/hydractl/provision-chroot')
-rwxr-xr-xshare/hydractl/provision-chroot11
1 files changed, 11 insertions, 0 deletions
diff --git a/share/hydractl/provision-chroot b/share/hydractl/provision-chroot
index ff771cf..e8ce9b5 100755
--- a/share/hydractl/provision-chroot
+++ b/share/hydractl/provision-chroot
@@ -48,6 +48,17 @@ done
hydra_sudo_run mkdir -p /var/chroot
hydra_sudo_run debootstrap --variant=minbase --arch $arch $version $WORK $mirror
+# Apt
+if [ "$version" != "sid" ]; then
+ echo "deb http://security.debian.org/ $version/updates main contrib non-free" | $SUDO tee $WORK/etc/apt/sources.list
+ echo "deb-src http://security.debian.org/ $version/updates main contrib non-free" | $SUDO tee $WORK/etc/apt/sources.list
+fi
+
+# Initial upgrade.
+echo "Applying initial upgrades..."
+hydra_sudo_run chroot $WORK/ apt-get update
+hydra_sudo_run chroot $WORK/ apt-get upgrade -y
+
# Arch specific procedures
if [ "$arch" == "armel" ] || [ "$arch" == "armhf" ]; then
if [ ! -f '/usr/bin/qemu-arm-static' ]; then