nginx support
fculpo opened this issue · comments
Can someone explain how to hide pasteboard behind a nginx server running https ?
when i access directly ip:4000, no problem, but if i use ip/nginx_location_name, it doesn't show any images, nor dynamic content (i got "image not found" errors, and blank page with just a little text).
Thanks in advance
Here is the nginx conf file for an https etherpad-lite behind nginx:
I suppose you can get inspiration from it to run pasteboard (as it's a nodejs service too).
++
Alex
Here's my stripped down nginx configuration for the dev version:
upstream app_pasteboard_dev {
server 127.0.0.1:4000;
}
server {
listen 0.0.0.0:80;
server_name dev.pasteboard.co dev.pasteboard;
location / {
proxy_set_header X-Real-IP $remote_addr;
proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for;
proxy_set_header Host $http_host;
proxy_set_header X-NginX-Proxy true;
proxy_pass http://app_pasteboard_dev/;
proxy_redirect off;
proxy_buffering off;
}
}
Might want to add the following to either the server or location stanza,
client_max_body_size 20m;
otherwise, you'll see 500 errors for 'client intended to send too large body' in /var/log/nginx/error.log