-
Notifications
You must be signed in to change notification settings - Fork 1
NGINX configuration
Julien Savard edited this page Feb 15, 2015
·
1 revision
Make sure you use at least NGINX 1.3.13 to use the websocket feature. Say you installed WalrusIRC in /var/www/walrusirc
on port 4200:
server {
listen 80;
listen [::]:80;
server_name walrusirc.example.com;
root /var/www/walrusirc/public;
error_page 404 /404.html;
error_page 502 =503 /503.html;
# Add either every non-static locations here, or just do location /
location ~ ^/(socket.io|logs)/ {
proxy_set_header Upgrade $http_upgrade;
proxy_set_header Connection "upgrade";
proxy_http_version 1.1;
proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for;
proxy_set_header Host $host;
proxy_pass http://localhost:4200;
}
}
Reload NGINX and your WalrusIRC installation should be accessible on http://walrusirc.example.com.