You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
47.5 RC. Issue #165. Option for Mongoose web server to listen on all IP addresses available.
In settings.json set: "listen_on": ["*", 54007] - this will make web server to listen on 127.0.0.1
and on 192.168.0.x and also on a public internet ip address. During testing I only confirmed
that it listened on local ip addresses (127.xxx and 192.xxx), I couldn't make it work for the internet
ip address - not sure if this is an issue in Mongoose web server, or or my router's port forwarding
wasn't configured properly. Note also that when listen_on is set to "*" then the SERVER_NAME
environment variable will still be set to 127.0.0.1 - this may cause issues in PHP scripts that
depend on that env variable. To fix it add this code at the top of all your PHP scripts:
<?php $_SERVER["SERVER_NAME"] = $_SERVER["HTTP_HOST"]; ?>
This will set SERVER_NAME to an ip address that the web server is being accessed from.
For example when accessing from 127.0.0.1 it will be set to that. When accessing from 192.168.0.2
then it will be 192.xxx in that case.
0 commit comments