test
sean 7 years ago
parent 2e799692f5
commit ae4a906da2

@ -359,10 +359,10 @@ echo "echo \"rpool/tmp /tmp zfs nodev,relatime 0 0\" >> /etc/fstab" >> /mnt/setu
echo 'echo ""' >> /mnt/setup-chroot.sh echo 'echo ""' >> /mnt/setup-chroot.sh
echo 'echo "Enabling SSH..."'>> /mnt/setup-chroot.sh echo 'echo "Enabling SSH..."'>> /mnt/setup-chroot.sh
echo "sed -ir 's/^ *# *ChallengeResponseAuthentication.*/ChallengeResponseAuthentication no/g' /etc/ssh/sshd_config" >> /mnt/setup-chroot.sh echo "sed -ir 's/^ *#? *ChallengeResponseAuthentication.*/ChallengeResponseAuthentication no/g' /etc/ssh/sshd_config" >> /mnt/setup-chroot.sh
echo "sed -ir 's/^ *# *PasswordAuthentication.*/PasswordAuthentication no/g' /etc/ssh/sshd_config" >> /mnt/setup-chroot.sh echo "sed -ir 's/^ *#? *PasswordAuthentication.*/PasswordAuthentication no/g' /etc/ssh/sshd_config" >> /mnt/setup-chroot.sh
echo "sed -ir 's/^ *# *UsePAM.*/UsePAM no/g' /etc/ssh/sshd_config" >> /mnt/setup-chroot.sh echo "sed -ir 's/^ *#? *UsePAM.*/UsePAM no/g' /etc/ssh/sshd_config" >> /mnt/setup-chroot.sh
echo "sed -ir 's/^ *# *PermitRootLogin.*/PermitRootLogin no/g' /etc/ssh/sshd_config" >> /mnt/setup-chroot.sh echo "sed -ir 's/^ *#? *PermitRootLogin.*/PermitRootLogin no/g' /etc/ssh/sshd_config" >> /mnt/setup-chroot.sh
echo "errors=\$(systemctl enable ssh 2>&1 1>/dev/null)">> /mnt/setup-chroot.sh echo "errors=\$(systemctl enable ssh 2>&1 1>/dev/null)">> /mnt/setup-chroot.sh
#&& ufw allow in on any from any to any port 22 proto tcp 2>&1 1>/dev/null #&& ufw allow in on any from any to any port 22 proto tcp 2>&1 1>/dev/null

Loading…
Cancel
Save