Created
December 13, 2010 11:36
-
-
Save fredrikhenne/738923 to your computer and use it in GitHub Desktop.
This file contains 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
#https://bbs.archlinux.org/viewtopic.php?id=103192 | |
#https://wiki.archlinux.org/index.php/AIF_Configuration_File#SOURCE¨ | |
#https://wiki.archlinux.org/index.php/Official_Arch_Linux_Install_Guide#Pre-Installation | |
#https://wiki.archlinux.org/index.php/Beginners'_Guide | |
#https://wiki.archlinux.org/index.php/GNOME#Base | |
#https://wiki.archlinux.org/index.php/Display_Manager#Loading_the_display_manager | |
SOURCE=net | |
SYNC_URL='ftp://ftp.df.lth.se/pub/archlinux/$repo/os/x86_64' | |
HARDWARECLOCK=UTC # UTC is the future, USE IT NOW or else....! | |
TIMEZONE=Europe/Stockholm | |
TARGET_GROUPS='base base-devel xorg gnome gnome-extra gnome-system-tools' | |
TARGET_PACKAGES_EXCLUDE= | |
TARGET_PACKAGES='e2fsprogs gksu gamin xf86-video-ati' | |
HOST_NAME="archmachine" | |
worker_intro () { | |
inform "Automatiskt installation startar om 10 sekunder. /dev/sda kommer att raderas och skrivas över. VILL DU AVBRYTA TRYCK CTRL + C" | |
sleep 10 | |
} | |
worker_runtime_network() { | |
dhcpcd eth0 | |
} | |
worker_install_packages() { | |
#HACK: the SYNC_URL is only used for the core repo. other repos fall back to /etc/pacman.d/mirrorlist. | |
echo "Server = $SYNC_URL" > /etc/pacman.d/tmp_mirrorlist | |
cat /etc/pacman.d/mirrorlist >> /etc/pacman.d/tmp_mirrorlist | |
mv /etc/pacman.d/tmp_mirrorlist /etc/pacman.d/mirrorlist | |
target_prepare_pacman core extra community | |
installpkg | |
if [ $? -ne 0 ] | |
then | |
echo "Error during package installation. exiting" | |
exit 1 | |
fi | |
} | |
worker_configure_system () { | |
prefill_configs | |
echo "configuring rc.conf" | |
sed -i "s/^HOSTNAME=.*/HOSTNAME=\"$HOST_NAME\"/" $var_TARGET_DIR/etc/rc.conf | |
sed -i 's/^MODULES=.*/MODULES=(fuse usblp)/' $var_TARGET_DIR/etc/rc.conf | |
sed -i 's/^DAEMONS=.*/DAEMONS=(syslog-ng klogd !pcmcia dbus crond @network @netfs gdm)/' $var_TARGET_DIR/etc/rc.conf | |
echo "configuring hosts.*" | |
sed -i "s/localhost$/localhost $HOST_NAME/g" $var_TARGET_DIR/etc/hosts | |
echo "Setting root password" | |
chroot $var_TARGET_DIR passwd | |
} | |
# These variables are mandatory | |
GRUB_DEVICE=/dev/sda | |
PARTITIONS='/dev/sda 100:ext2:+ 512:swap *:ext4' | |
BLOCKDATA='/dev/sda1 raw no_label ext2;yes;/boot;target;no_opts;no_label;no_params | |
/dev/sda2 raw no_label swap;yes;no_mountpoint;target;no_opts;no_label;no_params | |
/dev/sda3 raw no_label ext4;yes;/;target;no_opts;no_label;no_params' |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment