添加用户
adduser --disabled-password dongfg apt install sudo # 免密 dongfg ALL=(ALL) NOPASSWD:ALL vi /etc/sudoers.d/90-init-user
自动更新
apt install unattended-upgrades
ssh安全设置
... PermitRootLogin no ... PasswordAuthentication no ... Port 22222 #AddressFamily any ListenAddress 0.0.0.0
启用 ufw
Related: