Of course you have to serve it on the server. There are a few steps you have to take:
- Transfer your files to the server (think this is done)
- Login via SSH and execute a
npm install inside your app's directory.
- Change your
app.js (or whatever) to bind to your internet interface. The default is to have it bind to localhost so you won't be able to access it from outside your local.
- You will also need to open the port on the server. This involves using a reverse proxy (like nginx) to listen for a standard port (80) and redirect it to the port your app is listening. If you would like your app to listen on port 80 directly you would need to run it under
root user, which is not recommended. Try open the port with a iptables command like: iptables -A INPUT -p tcp --dport 9000 -j ACCEPT
- Inside your app's directory execute your
ng serve (or whatever)
This instructions are for development, not for production use.