Created
December 12, 2014 10:42
-
-
Save julianwachholz/320fb66f5ac288c1c068 to your computer and use it in GitHub Desktop.
Autoinstall ArchLinux on a existing OS
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/sh -e | |
ARCH_VERSION="2014.12.01" | |
ARCH_FILE="archlinux-bootstrap-$ARCH_VERSION-x86_64.tar.gz" | |
ARCH_BOOTSTRAP="http://archlinux.mirrors.ovh.net/archlinux/iso/$ARCH_VERSION/$ARCH_FILE" | |
ARCH_SUMS="http://archlinux.mirrors.ovh.net/archlinux/iso/$ARCH_VERSION/sha1sums.txt" | |
# download bootstrap image | |
cd /tmp | |
wget $ARCH_BOOTSTRAP | |
wget $ARCH_SUMS | |
# check SHA1 but ignore missing files | |
sha1sum -c sha1sums.txt | grep "$ARCH_FILE: OK" | |
tar xf $ARCH_FILE | |
# Use OVH mirror | |
echo "Server = http://archlinux.mirrors.ovh.net/archlinux/\$repo/os/\$arch" > /tmp/root.x86_64/etc/pacman.d/mirrorlist | |
# get the installer script | |
#wget "https://gist.github.com/julianwachholz/$GIST_ID/install.sh" | |
#mv install.sh /tmp/root.x86_64 | |
#chmod o+x /tmp/root.x86_64/install.sh | |
# Enter chroot | |
/tmp/root.x86_64/bin/arch-chroot /tmp/root.x86_64/ |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment