Skip to content

Instantly share code, notes, and snippets.

@jschwindt
Created October 8, 2019 16:47
Show Gist options
  • Save jschwindt/948d63f838b319b7a5d426ade4db560a to your computer and use it in GitHub Desktop.
Save jschwindt/948d63f838b319b7a5d426ade4db560a to your computer and use it in GitHub Desktop.
server {
listen 80;
server_name kartoffel.example.org;
keepalive_timeout 5;
root /var/www/kartoffel/current/public;
access_log /var/log/nginx/kartoffel.access.log;
error_log /var/log/nginx/kartoffel.error.log warn;
passenger_enabled on;
# Rails error pages
error_page 500 502 503 504 /500.html;
location = /500.html {
root /var/www/kartoffel/current/public;
}
location ~ ^/assets/ {
root /var/www/kartoffel/current/public;
gzip_static on; # to serve pre-gzipped version
expires max;
add_header Cache-Control public;
}
}
passenger_pre_start http://kartoffel.example.org/;
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment