DEV Community

loading...

Discussion on: Deploy your NodeJS App to a server with Docker

Collapse
mrwormhole profile image
Talha Altınel

Bad suggestion, web server/reverse proxy has to be outside of containers and only 1. Otherwise you will run into port issues with existing nginx containers when you deploy more web apps into a single VPS. Not to mention you will quickly reach ram's limit

Collapse
creekorful profile image
Aloïs Micard

RAM consumption for Nginx isn't that high, an HA instance may consumes <30MB RAM, see this link for more details.

For the port issue, what you can do is have a single Nginx instance running with privilege mode to bind in :80, :443. This way you still have process isolation and are covered in case someones exploit your web-server.

Thread Thread
mrwormhole profile image
Talha Altınel • Edited

That makes sense for a reverse proxy but for a server that can host static websites(monolith full stack applications) it can be a trouble to manage with volumes.

Collapse
arnu515 profile image