user www-data;
worker_processes auto;
worker_cpu_affinity auto;
pid /run/nginx.pid;
error_log /var/log/nginx/error.log;
include /etc/nginx/modules-enabled/*.conf;

events {
    use epoll;
    worker_connections 768;
    accept_mutex on;
}

http {
    # base
    include "/etc/nginx/mime.types";

    # http
    include "/etc/nginx/http/index.conf";
    # https
    include "/etc/nginx/https/index.conf";

    # enable websocket
    map $http_upgrade $connection_upgrade {
        default upgrade;
        '' close;
    }
}