server {
    listen 80;
    server_name localhost;

    root /usr/share/collectd-web/;
    autoindex off;

    location ~ \.cgi$ {
        fastcgi_pass unix:/var/run/fcgiwrap.socket;
        fastcgi_param SCRIPT_FILENAME $document_root$fastcgi_script_name;
        include fastcgi_params;
    }
}
