Be part of JetBrains PHPverse 2026 on June 9 – a free online event bringing PHP devs worldwide together.

cuartas15's avatar

Can't install dependencies globally

First of all I'm a total noob on server deployment and anything related so bear with me. Second, I'm not so sure if this is more a Forge or a Digital Ocean issue. I've gotten to the point where my application is deployed, it has it's own domain, the database is fine, composer and npm dependencies are in place, etc. I'm getting to the step of configuring Redis + Socket.io + Laravel Echo Server for broadcasting but it seems I'm not able to install Echo (npm install -g laravel-echo-server) due to missing permissions.

https://i.gyazo.com/2e370242f55a38815252195c206c015b.png

I've tried to change the folder permissions to even 777 but I get to another permission roadblocks down the line.

For the record, npm install (without the -g) is working perfectly to install my project's dependencies

I would appreciate any help on the matter.

Thanks in advance

0 likes
3 replies
cuartas15's avatar

Yes sir, that does the trick, thank you so much

Jaytee's avatar

Global files generally require sudo since you're modifying the actual server directory, rather than the local project directory.

Please or to participate in this conversation.