Q:

Running `npm install` on extremely low-specs machine

I want to host my node.js app on Google Compute Engine, with the lowest CPU possible (1 vCPU, 0.6GB). However, it seems that because this is so poor in either or both of its performance and memory, when I tried to run npm install --production on the VM via SSH, the installation just keeps hunging up for long, and then it is killed:
$ npm install --production

cloneCurrentTree → gunzTa ▐ ╢██████████████████████████░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░╟
Killed

The first line is my command and the last two lines are the output. I tried it on another, slightly more superior VM (1 vCPU, 1.7GB) and the installation worked without any problems. I tried both of them two times at each VM, for your information.
So my question is: Is it possible to npm install on the extremely poor machine environment? 

A:

I had that problem on a 512 MB RAM server. You have to enable SWAP so that the server uses hard drive for storing tmp data when it runs out of RAM.
Read how to do that

