server {
    listen 80;
    listen 8080;

    server_name apc.dev.gliders.vm;
    root /home/gliders/code/APC-Admin;

    error_log /var/log/nginx/apc.error.log;
    access_log /var/log/nginx/apc.access.log;

    location / {
        try_files $uri @apc;
    }

    # pass the PHP scripts to FastCGI server from upstream phpfcgi
    location @apc {
        fastcgi_pass phpfcgi;
        fastcgi_index index.php;
        fastcgi_buffers 256 4k;
        include fastcgi_params;
        fastcgi_param SCRIPT_FILENAME $document_root/index.php;
        fastcgi_param SCRIPT_NAME index.php;
        fastcgi_param HTTPS off;
    }
}