📌 📄 内容摘要:
lusheng (@skylusheng) 在 vps快捷开启密钥脚本 中发帖
sed -i 's/PermitRootLogin no/PermitRootLogin yes/g' /etc/ssh/sshd_config
sed -i 's/PasswordAuthentication yes/PasswordAuthentication no/g' /etc/ssh/sshd_config
sed -i 's/PubkeyAuthentication no/PubkeyAuthentication yes/g' /etc/ssh/sshd_config
sudo systemctl restart ssh
已经有公钥,怎么一键导入并开启密钥登录同时关闭密码登录,我用这个执行发现不成功
────────── 链接信息 ──────────
🔗 论坛链接: linux.do
📎 访问地址: https://linux.do/t/topic/480272/1
─────────────────────────────
📢 来源:LINUX DO