Caleb Igwe
Caleb Igwe

Reputation: 67

EACCES: permission denied, open '/home/site/wwwroot/node_modules/.cache/.eslintcache'

I deployed my react app to azure and on load, I got this error: Failed to compile

EACCES: permission denied, open '/home/site/wwwroot/node_modules/.cache/.eslintcache'

This error occurred during the build time and cannot be dismissed.

I have spent a couple of days trying to rectify it, all to no avail. Please, I need help. enter image description here

Upvotes: 1

Views: 2618

Answers (3)

samuelnihoul
samuelnihoul

Reputation: 269

You can chmod the file back to you. Actually in my case I had to change the ownership of the whole node_modules cache:

chmod a+wr node_modules/.cache

Upvotes: 0

BLOODY CRAFTER
BLOODY CRAFTER

Reputation: 1

The only way to overcome this issue is given below:

●Delete all files without (public and src).(if you delete public and src this will delete all your progress) ●Then create a new react app with [ $npx create-react-app ] ●exchange the public and src files with your project public and src ● npm start and hopefully it worked for you .

Upvotes: -1

AjayKumarGhose
AjayKumarGhose

Reputation: 4933

if you have a typo in your code and saved it, then .eslintcache doesn't get cleared and the error will appear in the server continuously . You have to delete .eslintcache. to overcome from this error.

References :

. How to deploy React app to azure

. GitHub issue .

Upvotes: 1

Related Questions