Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Compiling node-sass takes 10 minutes

We operate many small websites. We usually host them on Digital Ocean's $5-$10 servers.

Part of our deployment is compiling of Sass to CSS using node-sass.

On our latest server we experience a significant increase in compiling time for node-sass library (not the actual scss files). We're talking about 8-10 minutes, where in other projects it takes 30sec - 100sec.

We use node 8.11.1 (newest LTS) and yarn 1.6.0 (newest) with node-sass 4.8.3 (newest) on Ubuntu 16.04.4.

Is there any way to cache the compilation between deployments? Or is anyone aware why its taking so much time to compile node-sass?

like image 208
jakub_jo Avatar asked Apr 20 '18 09:04

jakub_jo


1 Answers

If someone finds this through search engine:

We did not find any solution for the issue. We scaled the droplet up and down back to it's original size and the problem was gone.

like image 184
jakub_jo Avatar answered Oct 13 '22 10:10

jakub_jo