HTTP 500 error page

Hello all,

I’d like to have nginx+passenger show the custom (Default) error pages when a HTTP 500 error occurs in my app.

I am running a rails 2.3 app on nginx 1.2 with passenger 3.0.7

Here is my nginx config file:

`#user nobody;
worker_processes 16;

error_log /opt/nginx/logs/error.log info;

pid /opt/nginx/logs/;
worker_rlimit_nofile 32768;

events {
worker_connections 2048;

http {
passenger_root /usr/lib/ruby/gems/1.8/gems/passenger-3.0.7;
passenger_ruby /usr/bin/ruby;

include       mime.types;
default_type  application/octet-stream;

#access_log  /opt/nginx/logs/access.log  main;

sendfile        on;
#tcp_nopush     on;

server {
    listen 80;
    server_name localhost;
    root /var/www/dashboard/current/public;
    passenger_enabled on;
    passenger_min_instances 1;

listen 443;

ssl on;

ssl_certificate /opt/nginx/conf/server.crt;

ssl_certificate_key /opt/nginx/conf/server.key;

    # Rails error pages
    error_page 500 502 503 504 /500.html;
    location = /500.html {
        root /var/www/dashboard/current/public;


In my dev env, app running on webrick, when the app generate a http 500 error I get the custom error page just fine.Any idea why the difference?