Sha256: 2afa6953314be61c4d831548d400cc001727911fb5bbffffc713e5cbd12bb5f3

Contents?: true

Size: 1.46 KB

Versions: 138

Compression:

Stored size: 1.46 KB

Contents

upstream <%= application %> {
<% mongrel_servers.times do |counter| -%>
  <%= "server 127.0.0.1:#{mongrel_port+counter};"  %>
<% end -%>
}

server {
    listen       80;
    server_name  <%= application %> <%= domain %> <% 4.times do |counter| %> <%= domain.sub(/.*?\./, "assets#{counter}.") %><% end %>;
    root <%= deploy_to %>/current/public;
    access_log <%= deploy_to %>/shared/log/<%= domain %>-access.log;
    error_log <%= deploy_to %>/shared/log/<%= domain %>-error.log;
    client_max_body_size  <%= nginx_client_max_body_size %>;

        if (-f $document_root/system/maintenance.html){
                rewrite  ^(.*)$  /system/maintenance.html last;
                break;
        }
        location / {
                proxy_set_header  X-Real-IP  $remote_addr;
                proxy_set_header  X-Forwarded-For $proxy_add_x_forwarded_for;
                proxy_set_header Host $http_host;
                proxy_redirect false;

                if (-f $request_filename/index.html) {
                        rewrite (.*) $1/index.html break;
                }
                if (-f $request_filename.html) {
                        rewrite (.*) $1.html break;
                }       
                if (!-f $request_filename) {
                        proxy_pass http://<%= application %>;
                        break;
                }
        }

        error_page   500 502 503 504  /50x.html;
        location = /50x.html {
                root   html;
        }
}

Version data entries

138 entries across 138 versions & 3 rubygems

Version Path
le1t0-deprec-2.1.6.068 lib/deprec/templates/mongrel/nginx_vhost.conf.erb
le1t0-deprec-2.1.6.067 lib/deprec/templates/mongrel/nginx_vhost.conf.erb
deprec-2.1.18 lib/deprec/templates/mongrel/nginx_vhost.conf.erb
deprec-2.1.17 lib/deprec/templates/mongrel/nginx_vhost.conf.erb
le1t0-deprec-2.1.6.066 lib/deprec/templates/mongrel/nginx_vhost.conf.erb
le1t0-deprec-2.1.6.065 lib/deprec/templates/mongrel/nginx_vhost.conf.erb
deprec-2.1.16 lib/deprec/templates/mongrel/nginx_vhost.conf.erb
le1t0-deprec-2.1.6.064 lib/deprec/templates/mongrel/nginx_vhost.conf.erb
le1t0-deprec-2.1.6.063 lib/deprec/templates/mongrel/nginx_vhost.conf.erb
le1t0-deprec-2.1.6.062 lib/deprec/templates/mongrel/nginx_vhost.conf.erb
le1t0-deprec-2.1.6.061 lib/deprec/templates/mongrel/nginx_vhost.conf.erb
le1t0-deprec-2.1.6.059 lib/deprec/templates/mongrel/nginx_vhost.conf.erb
le1t0-deprec-2.1.6.058 lib/deprec/templates/mongrel/nginx_vhost.conf.erb
deprec-2.1.14 lib/deprec/templates/mongrel/nginx_vhost.conf.erb
deprec-2.1.13 lib/deprec/templates/mongrel/nginx_vhost.conf.erb
deprec-2.1.12 lib/deprec/templates/mongrel/nginx_vhost.conf.erb
deprec-2.1.11 lib/deprec/templates/mongrel/nginx_vhost.conf.erb
deprec-2.1.10 lib/deprec/templates/mongrel/nginx_vhost.conf.erb
deprec-2.1.8 lib/deprec/templates/mongrel/nginx_vhost.conf.erb
le1t0-deprec-2.1.6.057 lib/deprec/templates/mongrel/nginx_vhost.conf.erb