SSL, nginx, location
-
I'm following this guide: https://docs.nodebb.org/en/latest/configuring/proxies/nginx.html
and it works great, but I'd like the forum to not be available directly from my.server.org, but from my.server.org/forumHowever, if I change
location /
to
location /forum...the CSS and images are unavailable. What am I doing wrong?
Thanks!
-
I had the same issue before, make sure to add the forum next to location in your nginz
Location /forum
And apart from the /forum on your local proxy change it on your configuration. Js on in your nodebb folder
Sorry am from mobile and it's kinda hard to paste code
-
Nginx:
location /forum { proxy_pass http://127.0.0.1:4567/forum; proxy_set_header Host $host; proxy_set_header X-Real-IP $remote_addr; proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for; proxy_redirect off; proxy_buffering off; proxy_http_version 1.1; proxy_set_header Upgrade $http_upgrade; proxy_set_header Connection "upgrade"; }
Apache:
<VirtualHost *:8080> ... </VirtualHost> ProxyRequests off <Proxy *> Order deny,allow Allow from all </Proxy> ProxyPass /socket.io/1/websocket ws://127.0.0.1:4567/socket.io/1/websocket ProxyPassReverse /socket.io/1/websocket ws://127.0.0.1:4567/socket.io/1/websocket ProxyPass /forum http://127.0.0.1:4567/forum ProxyPassReverse /forum http://127.0.0.1:4567/forum
-
config.json:
{ "url": "http://sub.domen.com/forum", "secret": "ecb356d8-120a-433c-866f-46589291e491", "database": "redis", "redis": { "host": "127.0.0.1", "port": "6379", "password": "goodpassword11233455677898", "database": "0" } }
Copyright © 2024 NodeBB | Contributors