Sha256: 66caa00ecd5e26039827b38a574f6bc21fb922e787a83c1cc77d821e6df7e25d

Contents?: true

Size: 1.31 KB

Versions: 30

Compression:

Stored size: 1.31 KB

Contents

upstream <%= app_name %>-backend {
  server unix:/apps/<%= app_name %>/current/tmp/sockets/puma.sock fail_timeout=0;
}

# Rewrite http traffic to https
server {
  server_name <%= app_name %>-mnoe.maestrano.io;
  listen 80;

  location / {
    rewrite ^ https://$host$request_uri? permanent;
  }
}

server {
  server_name  <%= @app_domain %>;
  listen       443;

  ssl on;
  ssl_certificate /etc/nginx/certificates/maestrano.io.wildcard-current/maestrano.io.wildcard.chained.crt;
  ssl_certificate_key /etc/nginx/certificates/maestrano.io.wildcard-current/maestrano.io.wildcard.key;

  root         /apps/<%= app_name %>/current/public;
  index        index.html index.htm;

  try_files  $uri/index.html $uri.html $uri @backend;

  location ^~ /assets/ {
    gzip_static on;
    expires max;
    add_header Cache-Control public;
  }

  location @backend {
    expires -1;
    add_header  Cache-Control "max-age=0, no-store, must-revalidate";

    proxy_set_header  X-Forwarded-Proto   https;
    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    off;
    proxy_pass        http://<%= app_name %>-backend;
  }

  error_page   500 502 503 504  /50x.html;

  location = /50x.html {
    root   html;
  }
}

Version data entries

30 entries across 30 versions & 1 rubygems

Version Path
mno-enterprise-core-3.4.0 lib/generators/mno_enterprise/templates/scripts/nginx/app
mno-enterprise-core-3.3.3 lib/generators/mno_enterprise/templates/scripts/nginx/app
mno-enterprise-core-3.3.2 lib/generators/mno_enterprise/templates/scripts/nginx/app
mno-enterprise-core-3.2.1 lib/generators/mno_enterprise/templates/scripts/nginx/app
mno-enterprise-core-3.3.1 lib/generators/mno_enterprise/templates/scripts/nginx/app
mno-enterprise-core-3.3.0 lib/generators/mno_enterprise/templates/scripts/nginx/app
mno-enterprise-core-3.2.0 lib/generators/mno_enterprise/templates/scripts/nginx/app
mno-enterprise-core-3.1.4 lib/generators/mno_enterprise/templates/scripts/nginx/app
mno-enterprise-core-3.0.7 lib/generators/mno_enterprise/templates/scripts/nginx/app
mno-enterprise-core-2.0.9 lib/generators/mno_enterprise/templates/scripts/nginx/app
mno-enterprise-core-3.1.3 lib/generators/mno_enterprise/templates/scripts/nginx/app
mno-enterprise-core-3.0.6 lib/generators/mno_enterprise/templates/scripts/nginx/app
mno-enterprise-core-2.0.8 lib/generators/mno_enterprise/templates/scripts/nginx/app
mno-enterprise-core-3.1.2 lib/generators/mno_enterprise/templates/scripts/nginx/app
mno-enterprise-core-3.0.5 lib/generators/mno_enterprise/templates/scripts/nginx/app
mno-enterprise-core-2.0.7 lib/generators/mno_enterprise/templates/scripts/nginx/app
mno-enterprise-core-2.0.6 lib/generators/mno_enterprise/templates/scripts/nginx/app
mno-enterprise-core-2.0.5 lib/generators/mno_enterprise/templates/scripts/nginx/app
mno-enterprise-core-3.1.1 lib/generators/mno_enterprise/templates/scripts/nginx/app
mno-enterprise-core-3.0.4 lib/generators/mno_enterprise/templates/scripts/nginx/app