    worker_processes auto;
#    pid        /tmp/nginx.pid;
    error_log stderr notice;
    #error_log /tmp/test.log error;
    env LAPIS_ENVIRONMENT;
    daemon off;

    events {
        worker_connections 16384;
    }

    http {
        variables_hash_max_size 1024;
        access_log off;
        include mime.types;
        lua_package_path 'CWD/?.lua;;';

        upstream database {
            postgres_server DBHOSTNAME dbname=hello_world user=benchmarkdbuser password=benchmarkdbpass;
        }
        init_by_lua 'require "resty.core"; lapis = require "lapis.init"';
        server {
            listen 8080;
            lua_code_cache on;
            charset "utf-8";

            location / {
                default_type text/html;
                content_by_lua_file "loader.lua";
            }

            location /static/ {
                alias static/;
            }

            location /favicon.ico {
              alias static/favicon.ico;
            }
            location = /query {
                internal;
                postgres_pass database;
                postgres_query $echo_request_body;
            }
        }
    }
