Skip to content

Instantly share code, notes, and snippets.


Kevin kvandenhaute

View GitHub Profile
kvandenhaute / default
Last active Aug 29, 2017
Example of a default server configuration for Nginx (sites-available/default).
View default
server {
listen 80 default; ## listen for ipv4; this line is default and implied
listen [::]:80 default ipv6only=on; ## listen for ipv6
# Make site accessible from http://localhost/
server_name localhost;
server_name_in_redirect off;
charset utf-8;
kvandenhaute / nginx.conf
Created Mar 28, 2013
Example of a good working Nginx configuration.
View nginx.conf
user www-data;
# As a thumb rule: One per CPU. If you are serving a large amount
# of static files, which requires blocking disk reads, you may want
# to increase this from the number of cpu_cores available on your
# system.
# The maximum number of connections for Nginx is calculated by:
# max_clients = worker_processes * worker_connections
worker_processes 1;
You can’t perform that action at this time.