#!/bin/sh################################################################################ This script let you install ArchLinux on a dedibox ## ## ################################################################################################################################################################ Edit the following variables ################################################################################# Mirror on which we will download the packages (no trailing slash)MIRROR=ftp://mir1.archlinuxfr.org# Path tot the current repo (on the mirror, no trailing slash)CURRENT=/archlinux/current/os/i686# Devices to mount (to get / , /boot , /home at least)#DEVS=(/dev/sda3 /dev/sda1 /dev/sda5 /dev/sda6)# Mout points for devices (same order that devices)#MOUNTS=(/ /boot /var /home)# Where to store temporary install files (the directory is created and removed)TMP=/mnt/install# Path where is mounted the new Arch instal (no trailing slash)ARCHPATH=/mnt# File to save outputsLOG=install.log################################################################################ You do not need to edit anything below these line ################################################################################# Create temporary directorymkdir -p $TMPcd $TMP# Get the base package list (minus lilo and grub)wget $MIRROR$CURRENT/setup/packages.txt#cat packages.txt | grep 'base/' | grep -v 'lilo' | grep -v 'grub' | sed -e "s/base/$MIRROR$CURRENT/g" > basePKGLIST=`cat packages.txt | grep 'base/' | grep -v 'lilo' | grep -v 'grub' | sed -e "s/base//g"`for i in $PKGLISTdo echo "$MIRROR$CURRENT$i" >> basedone# Download base packageswget -i base# Extract pacman package (to get pacman.static)tar xfz pacman-*.pkg.tar.gz# Create dummy pacman.confecho "[options]HoldPkg = pacman glibc[current]Server = file://$TMP" > pacman.conf# install base packagesusr/bin/pacman.static -A *.pkg.tar.gz -r $ARCHPATH --config pacman.conf# Remove temporary directorycd -rm -rf $TMP