2

Sorry if this is a stupid question or it doesn't make sense.

Basically what I'm trying to do is put my local web development project (using Nodejs/Express and MongoDB) onto a server that only consists of a command line interface.

The point is to run the application from the command line, and then access the app on port 3000. When I run the project locally I go to http://localhost:3000/ and it's there.

How can I make it so other users can access my application from their browsers?

  • 2
    Will the others be accessing the app on the same network or over the internet? What flavor of Linux are you running and what version? You can get this information by running the following commands cat /etc/issue and cat /etc/system-release. It is necessary you add this information to your question above so we know how to assist you. – Gordster Mar 19 at 6:59
  • 2
    The answer form is missing so I'll try to help here. There are a few though simple barriers between the client (web browser like Waterfox) and server (HTTP server). The primary one is the firewall, you might have to allow the firewall to allow traffic on the port (e.g. 3000) and you're obviously using the port on the client computer. If you can successfully load a page on the server from itself then try to get it working on the client. I work with Apache/PHP/MariaDB on Windows locally and Linux on live servers so I'm not familiar with your specific setup. – John Mar 19 at 16:30
  • 1
    When asking a question on a Stack site the more ravenous "regulars" will apathetically close or "mark as duplicate". Regardless there are plenty of good people willing to help. The key is to know how to ask a question. In this case I don't know if you can load a page on the server itself from itself. You need to think chronologically about how you're testing and what could be causing the issue. What might seem like a very tall wall of frustration is a grain of dirt that hardly gets noticed by advanced users so know the exact issue and how to not only ask though show what you've tried. :-) – John Mar 19 at 16:36
  • 1
    @John thanks so much John! I actually forgot I asked the question on here already (thought I had posted it on stack overflow) but didn't get an answer regardless so I appreciate it. I'll try to get more info and ask the question in a more specific way. Thanks again! – Emily Mar 19 at 18:23
  • 1
    @Emily I'm happy to help. I avoid more convoluted software (most do not) so if you're looking for a template for posting please feel free to use my posts. I imagine that even with 1 reputation that you'll still be able to edit posts (questions and answers) and see how the formatting works - do that and you'll give yourself a nice boost. Make sure your question matches the context of which Stack site you use. If you get stuck post the URL & I'll try to edit the question for you if you have any trouble. You're already further ahead then when I started & I built an entire web platform. 😉︎ – John Mar 19 at 18:33

Browse other questions tagged or ask your own question.