Bugfix: autologin

This commit is contained in:
2Shirt 2017-12-13 17:37:28 -07:00
parent c159602a70
commit cc2e42d348
4 changed files with 6 additions and 3 deletions

View file

@ -1,3 +0,0 @@
[Service]
ExecStart=
ExecStart=-/sbin/agetty --autologin wktech --noclear %I 38400 linux

View file

@ -155,6 +155,12 @@ function update_archlive() {
echo "useradd -m -s /bin/zsh -G autologin,power,storage,wheel -U $username" >> "$LIVE_DIR/airootfs/root/customize_airootfs.sh"
echo "echo '$username:$LINUX_TECH_PASSWORD' | chpasswd" >> "$LIVE_DIR/airootfs/root/customize_airootfs.sh"
# Tech user autologin
mkdir -p "$LIVE_DIR/airootfs/etc/systemd/system/getty@tty1.service.d"
echo "[Service]" >> "$LIVE_DIR/airootfs/etc/systemd/system/getty@tty1.service.d/autologin.conf"
echo "ExecStart=" >> "$LIVE_DIR/airootfs/etc/systemd/system/getty@tty1.service.d/autologin.conf"
echo "ExecStart=-/sbin/agetty --autologin $username --noclear %I 38400 linux" >> "$LIVE_DIR/airootfs/etc/systemd/system/getty@tty1.service.d/autologin.conf"
# Timezone
sed -i -r "s#zoneinfo/UTC#$LINUX_TIME_ZONE#g" "$LIVE_DIR/airootfs/root/customize_airootfs.sh"