Nginx is an open source web server for reverse proxying, caching, load balancing, media streaming, and other uses. It was initially created by Igor Sysoev in 1999 to solve the C10K problem which was about having network sockets handle a large number of clients simultaneously. Basically C10K means concurrently handling 10,000 connections. Nginx was built to be a fast, high performance server and is used by millions of websites and big name companies like Airbnb, Dropbox, Netflix, and Tumblr use it.
Nginx offers a different option than using Apache or other web servers and claims to be able to serve 10x more requests per server compared to Apache.
## Key file locations for Debian based distributions (Ubuntu included)
/etc/nginx/nginx.conf
- This is where you will find the global configuration values, what user the nginx process runs as, how many workers it has etc.
/etc/nginx/sites-available/*
- As one nginx instance can run multiple sites with separate configurations this is the directory where you will have the separate configuration files. Usually there is a file named 'default', but any file in this directory that can be parsed by nginx is available.
/etc/nginx/sites-enabled/*
- This is the directory that holds the site configurations that are actually live (enabled), you should not move files here directly, rather sym-link the files from the sites-available directory. Making a linked file in this directory does not make it live, for that you need to restart nginx or have it reload the config. Usually done via systemd.