server {
	listen 80 default_server;
	listen [::]:80 default_server;

	root /var/tracebox/web-interface;

	index index.php index.html;

	server_name _;

	client_max_body_size 200M;

	location / {
		try_files $uri $uri/ =404;
	}

	location /trace/ {
		root /var/tracebox/;
		try_files $uri $uri/ =404;
		autoindex on;
	}

	# pass PHP scripts to FastCGI server
	location ~ \.php$ {
		include snippets/fastcgi-php.conf;

		# With php-fpm (or other unix sockets):
		fastcgi_pass unix:/run/php/php-fpm.sock;

		# With php-cgi (or other tcp sockets):
		#fastcgi_pass 127.0.0.1:9000;
	}
}

server {
        listen 443;
        server_name _;
        return 301 http://$http_host$request_uri;
}
