Fix permissions for auto-login setup.
This commit is contained in:
parent
b78549e4fe
commit
f98837b0d0
@ -184,13 +184,13 @@ ssh "df -h . && sudo resize2fs /dev/mmcblk0p2 && df -h ."
|
||||
# From raspi-config: https://github.com/RPi-Distro/raspi-config/blob/c0ddae8a2e99ecf15759c7cb8f0681cb0e7ce63a/raspi-config#L1141
|
||||
# See also: https://github.com/futurice/chilipie-kiosk/issues/61#issuecomment-524622522
|
||||
working "Enabling auto-login to CLI"
|
||||
ssh "systemctl set-default multi-user.target"
|
||||
ssh "ln -fs /lib/systemd/system/getty@.service /etc/systemd/system/getty.target.wants/getty@tty1.service"
|
||||
ssh "ln -fs /lib/systemd/system/getty@.service /etc/systemd/system/getty.target.wants/getty@tty2.service"
|
||||
ssh "ln -fs /lib/systemd/system/getty@.service /etc/systemd/system/getty.target.wants/getty@tty3.service"
|
||||
ssh "mkdir -p /etc/systemd/system/getty@tty1.service.d"
|
||||
ssh "mkdir -p /etc/systemd/system/getty@tty2.service.d"
|
||||
ssh "mkdir -p /etc/systemd/system/getty@tty3.service.d"
|
||||
ssh "sudo systemctl set-default multi-user.target"
|
||||
ssh "sudo ln -fs /lib/systemd/system/getty@.service /etc/systemd/system/getty.target.wants/getty@tty1.service"
|
||||
ssh "sudo ln -fs /lib/systemd/system/getty@.service /etc/systemd/system/getty.target.wants/getty@tty2.service"
|
||||
ssh "sudo ln -fs /lib/systemd/system/getty@.service /etc/systemd/system/getty.target.wants/getty@tty3.service"
|
||||
ssh "sudo mkdir -p /etc/systemd/system/getty@tty1.service.d"
|
||||
ssh "sudo mkdir -p /etc/systemd/system/getty@tty2.service.d"
|
||||
ssh "sudo mkdir -p /etc/systemd/system/getty@tty3.service.d"
|
||||
ssh "echo -e '[Service]\nExecStart=\nExecStart=-/sbin/agetty --autologin pi --noclear %I \$TERM\n' | sudo tee /etc/systemd/system/getty@tty1.service.d/autologin.conf"
|
||||
ssh "echo -e '[Service]\nExecStart=\nExecStart=-/sbin/agetty --autologin pi --noclear %I \$TERM\n' | sudo tee /etc/systemd/system/getty@tty2.service.d/autologin.conf"
|
||||
ssh "echo -e '[Service]\nExecStart=\nExecStart=-/sbin/agetty --autologin pi --noclear %I \$TERM\n' | sudo tee /etc/systemd/system/getty@tty3.service.d/autologin.conf"
|
||||
|
||||
Loading…
Reference in New Issue
Block a user