'Nestjs on EC2: JavaScript heap out of memory issue
I am running nest project on t2 micro. Initially it was working fine but now after adding some other modules, it hangs while making build and says "Javascript heap out of memory".
Please help me with the possible reasons on why this might happen.
Solution 1:[1]
--max-old-space-size can increase heap memory
connect ssh to ec2 and open the .bashrc file using nano like so:
nano ~/.bashrc
The remaining steps are similar with the Mac steps from above, except we would most likely be using ~/.bashrc by default (as opposed to ~/.zshrc). So these values would need to be substituted!
Sources
This article follows the attribution requirements of Stack Overflow and is licensed under CC BY-SA 3.0.
Source: Stack Overflow
| Solution | Source |
|---|---|
| Solution 1 | bhavesh |
