73 lines
2.4 KiB
Plaintext
73 lines
2.4 KiB
Plaintext
|
#
|
||
|
# this is the nginx config for zammad
|
||
|
#
|
||
|
|
||
|
upstream zammad-railsserver {
|
||
|
server 127.0.0.1:3000;
|
||
|
}
|
||
|
|
||
|
upstream zammad-websocket {
|
||
|
server 127.0.0.1:6042;
|
||
|
}
|
||
|
|
||
|
server {
|
||
|
listen 443 ssl http2;
|
||
|
listen [::]:443 ssl http2;
|
||
|
|
||
|
# replace 'localhost' with your fqdn if you want to use zammad from remote
|
||
|
server_name support.libraryofcode.us;
|
||
|
|
||
|
root /opt/zammad/public;
|
||
|
|
||
|
access_log /var/log/nginx/zammad.access.log;
|
||
|
error_log /var/log/nginx/zammad.error.log;
|
||
|
|
||
|
client_max_body_size 50M;
|
||
|
ssl_certificate /etc/nginx/ssl/globalsign.chain.crt;
|
||
|
|
||
|
ssl_certificate_key /etc/nginx/ssl/globalsign.key.pem;
|
||
|
#ssl_session_cache builtin:1000 shared:SSL:10m;
|
||
|
ssl_protocols TLSv1 TLSv1.1 TLSv1.2;
|
||
|
ssl_ciphers HIGH:!aNULL:!eNULL:!EXPORT:!CAMELLIA:!DES:!MD5:!PSK:!RC4;
|
||
|
ssl_prefer_server_ciphers on;
|
||
|
#ssl_session_cache builtin:1000 shared:SSL:10m;
|
||
|
|
||
|
#ssl_protocols TLSv1 TLSv1.1 TLSv1.2;
|
||
|
|
||
|
#ssl_ciphers HIGH:!aNULL:!eNULL:!EXPORT:!CAMELLIA:!DES:!MD5:!PSK:!RC4;
|
||
|
|
||
|
#ssl_prefer_server_ciphers on;
|
||
|
|
||
|
ssl_protocols TLSv1.2; # Dropping SSLv3, ref: POODLE
|
||
|
# ssl_prefer_server_ciphers on;ssl_session_cache shared:SSL:10m;
|
||
|
# ssl_ciphers ECDHE-RSA-AES256-GCM-SHA512:DHE-RSA-AES256-GCM-SHA512:ECDHE-RSA-AES256-GCM-SHA384:DHE-RSA-AES256-GCM-SHA384:ECDHE-RSA-AES256-SHA384;
|
||
|
ssl_dhparam /etc/nginx/dhparam.pem;ssl_ecdh_curve secp384r1;
|
||
|
|
||
|
location ~ ^/(assets/|robots.txt|humans.txt|favicon.ico) {
|
||
|
expires max;
|
||
|
}
|
||
|
|
||
|
location /ws {
|
||
|
proxy_http_version 1.1;
|
||
|
proxy_set_header Upgrade $http_upgrade;
|
||
|
proxy_set_header Connection "Upgrade";
|
||
|
proxy_set_header CLIENT_IP $remote_addr;
|
||
|
proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for;
|
||
|
proxy_set_header X-Forwarded-Proto $scheme;
|
||
|
proxy_read_timeout 86400;
|
||
|
proxy_pass http://zammad-websocket;
|
||
|
}
|
||
|
|
||
|
location / {
|
||
|
proxy_set_header Host $http_host;
|
||
|
proxy_set_header CLIENT_IP $remote_addr;
|
||
|
proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for;
|
||
|
proxy_set_header X-Forwarded-Proto $scheme;
|
||
|
proxy_read_timeout 300;
|
||
|
proxy_pass http://zammad-railsserver;
|
||
|
|
||
|
gzip on;
|
||
|
gzip_types text/plain text/xml text/css image/svg+xml application/javascript application/x-javascript application/json application/xml;
|
||
|
gzip_proxied any;
|
||
|
}
|
||
|
}
|