Commit 169d2a71 authored by Christian Rebischke's avatar Christian Rebischke Committed by Christian Rebischke
Browse files

add python and new reflector-init service

parent 44a84cbc
......@@ -66,6 +66,23 @@ ExecStart=/usr/bin/pacman-key --populate archlinux
WantedBy=multi-user.target
EOF
# Add service for running reflector on first boot
cat <<EOF >/etc/systemd/system/reflector-init.service
[Unit]
Description=Initializes mirrors for the VM
After=network.target
Wants=network.target
ConditionFirstBoot=yes
[Service]
Type=oneshot
RemainAfterExit=yes
ExecStart=reflector --age 12 --protocol https --sort rate --save /etc/pacman.d/mirrorlist
[Install]
WantedBy=multi-user.target
EOF
# enabling important services
systemctl daemon-reload
systemctl enable sshd
......@@ -73,6 +90,7 @@ systemctl enable haveged
systemctl enable systemd-networkd
systemctl enable systemd-resolved
systemctl enable pacman-init.service
systemctl enable reflector-init.service
if [ -b "/dev/sda" ]; then
grub-install /dev/sda
......
......@@ -25,7 +25,7 @@ mkswap "${device}1"
mkfs.ext4 -L "rootfs" "${device}2"
mount "${device}2" /mnt
pacstrap /mnt base linux grub openssh sudo polkit haveged netctl
pacstrap /mnt base linux grub openssh sudo polkit haveged netctl python reflector
swapon "${device}1"
genfstab -p /mnt >>/mnt/etc/fstab
swapoff "${device}1"
......
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment