F
F
frontendo2017-12-31 00:57:56
Software Deployment
frontendo, 2017-12-31 00:57:56

How to properly deploy nodejs applications?

do you need to build a webpack bundle, for example, or fill in all the unassembled and do npm install on the server?

Answer the question

In order to leave comments, you need to log in

2 answer(s)
D
Dmitry Alekseev, 2017-12-31
@Zatmil

It all depends on the goals and scope. Imagine if you have a bundle >5Mb after compression.
At the same time, not all customers have their own server, even vps. Therefore, only a bundle is possible.
But I still prefer deploying to the server and procuring through nginx

O
OnYourLips, 2017-12-31
@OnYourLips

It is correct to compile not on the server (but on the CI / CD worker, although in a small project of one person and on a local machine it will do). Test this collected and then copy to the server.
Reasons 2:
1. We are testing exactly what will work in production.
2. No need to install compilers, etc. to the server.

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question