Created
October 25, 2017 13:14
-
-
Save ajtrichards/7d83f1e3dbfa7d1822a4f52b2d3f08f9 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
daemon off; | |
pid /tmp/nginx.pid; | |
error_log /dev/stderr info; | |
worker_processes auto; | |
events { | |
worker_connections 1024; | |
} | |
http { | |
gzip on; | |
gzip_disable "msie6"; | |
gzip_vary on; | |
gzip_proxied any; | |
gzip_comp_level 6; | |
gzip_buffers 16 8k; | |
gzip_http_version 1.1; | |
gzip_types text/plain text/css application/json application/x-javascript text/xml application/xml application/xml+rss text/javascript; | |
log_format ea '$remote_addr - $remote_user [$time_local] "$request" $status $body_bytes_sent "$http_referer" "$http_user_agent" "$http_x_forwarded_for" "$http_x_correlation_id" $request_time $upstream_response_time "{{ env "APP"}}" "{{ env "HOSTNAME"}}"'; | |
include /etc/nginx/mime.types; | |
default_type application/octet-stream; | |
access_log syslog:server=sumologic-syslog ea; | |
error_log syslog:server=sumologic-syslog; | |
sendfile off; | |
real_ip_header X-Forwarded-For; | |
set_real_ip_from 0.0.0.0/0; | |
index index.php index.html; | |
server { | |
listen 80 default; | |
root /var/www/public; | |
location ~ /\. { | |
deny all; | |
access_log off; | |
log_not_found off; | |
} | |
location / { | |
try_files $uri $uri/ /index.php?$query_string; | |
} | |
location ~ \.php$ { | |
try_files $uri /index.php =404; | |
fastcgi_split_path_info ^(.+\.php)(/.+)$; | |
fastcgi_pass 127.0.0.1:9000; | |
fastcgi_index index.php; | |
fastcgi_param SCRIPT_FILENAME $document_root$fastcgi_script_name; | |
include fastcgi_params; | |
} | |
} | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment