diff options
authorAndreas Baumann <>2016-10-05 20:11:23 +0200
committerAndreas Baumann <>2016-10-05 20:11:23 +0200
commit1e80876049645c597036c263aa0cefa0597ae4df (patch)
parent0f5ecab2c42b76753848cd4213336b2dd225d95c (diff)
removed some old stuff
1 files changed, 0 insertions, 140 deletions
diff --git a/Attic/ b/Attic/
deleted file mode 100755
index 9feca5e..0000000
--- a/Attic/
+++ /dev/null
@@ -1,140 +0,0 @@
-#!/bin/bash -x
-echo "Installing minimalistic base system.."
-sgdisk -Z ${INSTALL_DRIVE}
-sgdisk -a 2048 -o ${INSTALL_DRIVE}
-sgdisk -n ${PARTITION_BOOT}:0:+100M ${INSTALL_DRIVE}
-sgdisk -t ${PARTITION_BOOT}:ef02 ${INSTALL_DRIVE}
-sgdisk -n ${PARTITION_SWAP}:0:+900M ${INSTALL_DRIVE}
-sgdisk -t ${PARTITION_SWAP}:8200 ${INSTALL_DRIVE}
-sgdisk -t ${PARTITION_ROOT}:8300 ${INSTALL_DRIVE}
-sgdisk -G ${INSTALL_DRIVE}
-mkdir -p ${MOUNT_PATH}
-#mkdir ${MOUNT_PATH}/boot
-#export http_proxy=
-export no_proxy=localhost,
-# use our local cache
-sed -i '/\[core\]/aServer =$repo/os/$arch' /etc/pacman.conf
-sed -i '/\[extra\]/aServer =$repo/os/$arch' /etc/pacman.conf
-sed -i '/\[community\]/aServer =$repo/os/$arch' /etc/pacman.conf
-# switch off signature for now
-sed -i 's/^SigLevel.*/SigLevel = Never/g' /etc/pacman.conf
-pacstrap ${MOUNT_PATH} filesystem grep findutils coreutils glibc bash pacman mkinitcpio linux dhcpcd systemd
-# use our local cache in installed pacman
-sed -i '/\[core\]/aServer =$repo/os/$arch' ${MOUNT_PATH}/etc/pacman.conf
-sed -i '/\[extra\]/aServer =$repo/os/$arch' ${MOUNT_PATH}/etc/pacman.conf
-sed -i '/\[community\]/aServer =$repo/os/$arch' ${MOUNT_PATH}/etc/pacman.conf
-# add our local packages into a separate repository
-printf "\n[myrepo]\nServer =\044repo/os/\044arch\n" >> ${MOUNT_PATH}/etc/pacman.conf
-# synchronize package databases for installed pacman
-arch-chroot ${MOUNT_PATH} pacman -Sy
-# switch off signature for now in installed pacman
-sed -i 's/^SigLevel.*/SigLevel = Never/g' ${MOUNT_PATH}/etc/pacman.conf
-arch-chroot ${MOUNT_PATH} pacman --noconfirm -S grub-bios sed
-mkdir ${MOUNT_PATH}/boot/grub/locale/
-cp ${MOUNT_PATH}/usr/share/locale/en@quot/LC_MESSAGES/ ${MOUNT_PATH}/boot/grub/locale/
-# disable quiet mode, set text mode instead of graphical mode
-# also ban cirrus KVM
-# set correct path of systemd binary (symlink /sbin/init has gone)
-sed -i 's/GRUB_CMDLINE_LINUX_DEFAULT="quiet"/GRUB_CMDLINE_LINUX_DEFAULT="modprobe.blacklist=cirrus init=\/usr\/lib\/systemd\/systemd console=ttyS0,9600n8"/g' ${MOUNT_PATH}/etc/default/grub
-sed -i 's/GRUB_GFXMODE=auto/GRUB_GFXMODE=text/g' ${MOUNT_PATH}/etc/default/grub
-sed -i 's/GRUB_TERMINAL_INPUT=console/GRUB_TERMINAL_INPUT=serial/g' ${MOUNT_PATH}/etc/default/grub
-sed -i 's/#GRUB_TERMINAL_OUTPUT=console/GRUB_TERMINAL_OUTPUT=serial/g' ${MOUNT_PATH}/etc/default/grub
-echo 'GRUB_SERIAL_COMMAND="serial --speed=9600 --unit=0 --word=8 --parity=no --stop=1"' >> ${MOUNT_PATH}/etc/default/grub
-arch-chroot ${MOUNT_PATH} grub-mkconfig -o /boot/grub/grub.cfg
-arch-chroot ${MOUNT_PATH} grub-install --target=i386-pc --recheck ${INSTALL_DRIVE}
-genfstab -p ${MOUNT_PATH} >> ${MOUNT_PATH}/etc/fstab
-sed -i 's/^#en_US.UTF-8 UTF-8/en_US.UTF-8 UTF-8/g' ${MOUNT_PATH}/etc/locale.gen
-arch-chroot ${MOUNT_PATH} locale-gen
-echo LANG=en_US.UTF-8 > ${MOUNT_PATH}/etc/locale.conf
-ln -s /usr/share/zoneinfo/Europe/Zurich ${MOUNT_PATH}/etc/localtime
-arch-chroot ${MOUNT_PATH} hwclock --systohc --utc
-echo "archiso" > ${MOUNT_PATH}/etc/hostname
-arch-chroot ${MOUNT_PATH} systemctl enable dhcpcd@ens3.service
-arch-chroot ${MOUNT_PATH} sh -c "echo 'root:123qwe' | chpasswd"
-# synchronized time is a requirement, install and configure ntp
-# we use a standard NTP server, later we can change that via cfengine
-# we don't have a network here (yet, still chrooted)
-arch-chroot ${MOUNT_PATH} pacman --noconfirm -S ntp
-#while ! ping -c1 &>/dev/null; do :; done
-#arch-chroot ${MOUNT_PATH} ntpdate
-arch-chroot ${MOUNT_PATH} systemctl enable ntpd.service
-# monitord needs netstat
-arch-chroot ${MOUNT_PATH} pacman --noconfirm -S net-tools
-# we use 'git' to manage our promises
-arch-chroot ${MOUNT_PATH} pacman --noconfirm -S git
-arch-chroot ${MOUNT_PATH} pacman --noconfirm -S cfengine
-# install rules for the machine from git
-# no net, must be done as cfengine rule, anyway, rule distribution should
-# happen only on generated cfengine masters
-#arch-chroot ${MOUNT_PATH} git clone ${GIT_REPO} /srv/cfengine/masterfiles
-# enable cfengine
-arch-chroot ${MOUNT_PATH} systemctl enable cf-execd.service
-arch-chroot ${MOUNT_PATH} systemctl enable cf-monitord.service
-arch-chroot ${MOUNT_PATH} systemctl enable cf-serverd.service
-# for debugging
-#echo "Installation.. press any key to reboot."
-echo "Unmounting installation mount points.."
-#umount ${MOUNT_PATH}/boot
-umount ${MOUNT_PATH}
-echo "Done.. Rebooting system.."
-sleep 3
-systemctl reboot
-} 2>&1 | tee -a /dev/ttyS0