- Install Debian
Switch to root (su -
), install sudo
(apt-get install sudo
)
Add user to sudoers: adduser <username> sudo
Log off and back on to apply group changes.
Download curl: sudo apt-get install curl -y
sudo apt-get install vim -y
Get .vimrc
: wget https://raw.githubusercontent.com/jaredharley/my-stuff/master/linux/.vimrc -O ~/.vimrc
Copy to root
: sudo cp ~/.vimrc /root/.vimrc
sudo apt-get install git -y
Set up identity:
$ git config --global user.name "John Doe"
$ git config --global user.email [email protected]`
$ git config --global core.editor vim
Install python: sudo apt-get install python3 -y
Get the nginx signing key: wget -qO - https://nginx.org/keys/nginx_signing.key | sudo apt-key add -
Create the apt source: sudo vim /etc/apt/sources.list.d/nginx.list
Add the sources:
deb http://nginx.org/packages/debian/ codename nginx
deb-src http://nginx.org/packages/debian/ codename nginx
Update and install nginx: sudo apt-get update && sudo apt-get install nginx
Verify nginx is working: curl localhost
(Instructions from nginx)
Install ufw: sudo apt-get install ufw
Configure ufw:
$ sudo ufw limit in ssh
$ sudo ufw allow in http
$ sudo ufw allow in https
Enable ufw: sudo ufw enable
Check status: sudo ufw status verbose