node.js - Access site from local network. It sends requests to localhost server, but the server is on the machine, that serves the site -
i creating app. build nodejs on server. consists of several servers. fronted sends requests servers on localhost fetch data local servers ( urls fetching data on client localhost:3000/fetch_some). when want visit site other computer of local network ( write in browser ip of computer fronted , servers, 192.168.0.4:frontend_app_port
), front side trying fetch data localhost of computer running on, , not work, because there no servers, serves data on it. how deal it? configure front send requests 192.168.0.4
/(detect computer local network ip) . or there issues it? docker right fit case?
you need use server's name or address, can't reach end referring localhost front-end code.
Comments
Post a Comment