]> gitweb.fluxo.info Git - hydra.git/commitdiff
More fixes at provision-chroot
authorSilvio Rhatto <rhatto@riseup.net>
Sat, 12 Mar 2016 14:35:24 +0000 (11:35 -0300)
committerSilvio Rhatto <rhatto@riseup.net>
Sat, 12 Mar 2016 14:35:24 +0000 (11:35 -0300)
share/hydractl/provision-chroot

index 06720c7cc47520f4a6a2b74cf35a5afc8ec7e2d9..c989f6332573e750c5eefddf051410a60b1e0d45 100755 (executable)
@@ -50,10 +50,14 @@ hydra_sudo_run mkdir -p /var/chroot
 hydra_sudo_run debootstrap --variant=minbase --arch $arch $version $WORK/ $mirror
 
 # Arch specific procedures
-if [ "$arch" != "armel" ] && [ "$arch" != "armhf" ]; then
+if [ "$arch" == "armel" ] || [ "$arch" == "armhf" ]; then
+  if [ ! -f '/usr/bin/qemu-arm-static' ]; then
+    hydra_sudo run apt-get install qemu-user-static
+  fi
+
   hydra_sudo_run cp /usr/bin/qemu-arm-static $WORK/usr/bin/
   $CHROOT /debootstrap/debootstrap --second-stage
 fi
 
-echo "$hostname.$domain" | hydra_sudo_run tee /var/chroot/squeeze/etc/hostname > /dev/null
+echo "$hostname.$domain" | hydra_sudo_run tee $WORK/etc/hostname > /dev/null
 $CHROOT apt-get install locales