Skip to content

Instantly share code, notes, and snippets.

@AlexZeitler
Created October 9, 2018 11:05
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save AlexZeitler/0ebd34721afa2eadd28ea9673b11031d to your computer and use it in GitHub Desktop.
Save AlexZeitler/0ebd34721afa2eadd28ea9673b11031d to your computer and use it in GitHub Desktop.
user nginx;
worker_processes 1;
error_log /var/log/nginx/error.log warn;
pid /var/run/nginx.pid;
events {
worker_connections 1024;
}
http {
include /etc/nginx/mime.types;
default_type application/octet-stream;
log_format main '$remote_addr - $remote_user [$time_local] "$request" '
'$status $body_bytes_sent "$http_referer" '
'"$http_user_agent" "$http_x_forwarded_for"';
access_log /var/log/nginx/access.log main;
sendfile on;
#tcp_nopush on;
keepalive_timeout 65;
gzip_min_length 1000;
gzip_buffers 4 8k;
gzip_http_version 1.0;
gzip_disable "msie6";
gzip_types text/plain text/css application/json text/html application/javascript;
gzip_vary on;
server {
listen 443 ssl;
server_name example.org;
ssl_certificate /app/ssl/apiserver.crt;
ssl_certificate_key /app/ssl/apiserver.key;
location / {
proxy_pass http://iis:9980; // second file has 9990 here
proxy_http_version 1.1;
proxy_set_header Upgrade $http_upgrade;
proxy_set_header Connection 'upgrade';
proxy_set_header Host $host;
proxy_cache_bypass $http_upgrade;
gzip on;
# set client body size to 5M #
client_max_body_size 5M;
}
}
include /etc/nginx/conf.d/*.conf;
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment