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

benxmy@gmail.com's avatar

Appropriate Permissions for /bootstrap/cache/

I currently use envoyer to deploy my applications to private hosting resources. Recently (not sure when exactly this happened), after deploying I started getting an error. Ultimately, I tracked this down to a permissions issue with the /bootstrap/cache folder.

I resolved this by setting the folder permissions to 777 (sudo chmod -R 777 /bootstrap/cache/). I added this command as a deployment hook and it works. However, it seems to me that there's a security issue with 777 permissions. I've tried various permissions variations, to no avail. Anyone have any insight on this?

0 likes
1 reply
benxmy@gmail.com's avatar
Level 4

Resolved this. There were two steps:

  1. The user that was doing the deployment was in the primary group of root - I changed that to www-data
  2. I updated the chmod to: sudo chmod -R ug+rwx bootstrap/cache

Please or to participate in this conversation.