Add SSH as flavour

This commit is contained in:
maride 2017-09-19 13:49:02 +02:00
parent 039d2db196
commit bc13ac0712

14
flavours/ssh.flavour/install.sh Executable file
View File

@ -0,0 +1,14 @@
#!/bin/sh
echo "~> Install openssh package"
pacstrap /mnt openssh
echo "~> Patch /etc/ssh/sshd_config...:"
echo " * disallow passwords."
arch-chroot /mnt sed -i "s/^#PasswordAuthentication .*$/PasswordAuthentication no/g" /etc/ssh/sshd_config
echo " * force SSH keys."
arch-chroot /mnt sed -i "s/^#PubkeyAuthentication .*$/PubkeyAuthentication yes/g" /etc/ssh/sshd_config
echo " * enable on boot."
arch-chroot /mnt systemctl enable sshd
amf_return=0