Home > Linux Knowledge > Ubuntu Server setup
published 2024-01-03, updated 2024-01-03
- useradd -d /home/user -m user
- passwd -S user
- usermod -aG sudo user
- ssh-copy-id user@server.domain
- ssh user@server.domain -> RSA ID promt should appear
- chsh -s /bin/bash
- sudo apt install tmux micro git apache2 certbot python3-certbot-apache
TODO: Harden server
- uwf only port 22, 80, 443
- sudo apt install ufw
- sudo ufw allow 22
- sudo ufw allow 80
- sudo ufw allow 443
- sudo ufw status
- sudo ufw enable
- ssh only rsa auth