Speeding up NPM package install -
when deploy app aws, it's copied new directory, npm install same packages, during each deploy, can take lot of time. of these packages haven't changed between builds (if @ all), having full npm-install seems waste.
my app server runs bunch of different node apps, installing globally isn't option. instead i'd have app store it's node packages in location isn't wiped out during deployment, have option update packages necessary during npm install
.
does npm have concept of app-specific module directory isn't located in subfolder of app? way can delete app folder, , not have reinstall same packages on , on again.
i achieve using symlinks, or migrating current node_module directory.
if lock down dependencies versions, npm cache packages. installation wouldn't take longer.
if prefer not this, can install dependencies globally , link them npm link
command (which creating symlink yourself!). then, it'll update globally installed packages regularly.
Comments
Post a Comment