Answer the question
In order to leave comments, you need to log in
NodeJS to collect in one file?
Good day to everyone who reads!
I ask for a little hint - is it possible to build a NodeJS project with dependencies into a file, something like war / jar (like that)?
I only find information about creating an npm module, but this is not what I want.
The task is actually to collect this file and send it to the prod.
At the moment, sending files is implemented, let's say packed in a rar archive.
If there is such an opportunity, I will be grateful for a link or a resource with a description)
Answer the question
In order to leave comments, you need to log in
is it possible to build a NodeJS project with dependencies into a fileThere is an opportunity to collect in binarnik. If the weight, of course, does not bother you. There are archiving tools (don't confuse archiving with compression).
I do this: project in git, settings in .gitignore (if they are stored in a file) and node_modules. All dependencies are in package.json. On prod I roll out directly from the master branch of the git, then npm install, then pm2 start/save/restart
Didn't find what you were looking for?
Ask your questionAsk a Question
731 491 924 answers to any question