I am building a project for university with Angular 5. I built two separate services:
- parentFolder
- InputService
- package.json
- ...
- WebClient
- package.json
- ...
- InputService
My folder structure has a parent folder called projectX
and within it two sub-folders who both have their own package.json
etc. They are separate projects but exist within the same parentFolder. I set up a EC2 instance and have succesfully installed all dependencies there incl. node, npm and the correct version of angular CLI.
Locally, i start my project like so:
ng serve --port 6060
for the input service and
ng serve --port 4200
for the WebClient. I already ran ng build --prod
succesfully ON THE SERVER (via ssh) and created two dist folders (one within each folder). I now want to access both my services from within "the internet". I already set up inbound rules for my EC2 instance which should allow connection.
What is the easiest way to make my two dist folders available? Should i use express? I tried to use a pm2 http server which did not work.
Dont hesitate to ask if you have further questions.