Nginx.conf file setup comment and guidance will be appreciated

I was hoping to get some guidance on my nginx.conf file. I do not have much
experience working with Lucee servers running nginx and am trying to fine
tune my nginx.conf file so that I do not get 503 timeouts or 502 bad
gateway errors. I would appreciate any comments and guidance from the
lucee community on how to best configure nginx.conf for lucee.

My setup is Ubuntu 14.04 + nginx/1.4.6 installed

My current settings as follows:

worker_processes auto;

events {
worker_connections 2048;

http {

include mime.types;

# upstream configuration - configure additional servers and options for 

load balancing
# upstream lucee {
# server;
# }

server {

    listen       80;
    server_name  localhost;

    root   /opt/lucee/tomcat/webapps/ROOT;
    index  index.cfm;

    location ~ \.css$ {
        expires 4h;
    location ~ \.js$ {
        expires 4h;

    # NGINX handles static files
    location ~* 


        expires 30d;

    location / {
        # proxy_redirect off;
        proxy_pass http://localhost:8888/;

        proxy_http_version 1.1;
        proxy_set_header Connection "";

        proxy_set_header x-forwarded-host $host;
        proxy_set_header x-forwarded-server $host;
        proxy_set_header x-forwarded-for $proxy_add_x_forwarded_for;
        proxy_set_header x-forwarded-proto $scheme; 
        proxy_set_header x-forwarded-port $server_port;
        proxy_set_header x-real-ip $remote_addr;

# Custom Settings to Prevent 503/502
        client_max_body_size        32m;
        client_body_buffer_size     800k;
  proxy_connect_timeout       900;
        proxy_send_timeout          900;
        proxy_read_timeout          900;

        proxy_buffer_size           128k;
        proxy_buffers               4 256k;
        proxy_busy_buffers_size     256k;

        # proxy_intercept_errors on;