1

I'm adding products to my development website and I've noticed that images are not showing on the front end. After inspecting these, I can see that the chown user and group is correct but the file permissions of these images are set to 666. Is there a way I can make Magento correctly set these to 644 without having to set a cron job up?

0

Magento sets file permissions whenever we write files, like static view files, to the file system. The permissions differ by mode but ownership should always be the web server user.

In developer mode, directories have 770 permissions and files have 660. In production mode, directories have 750 and files have 640.

Ownership is kind of tricky and it confuses people so use this topic to get full details.

  • I understand that the files need 644 and directories are to have 770 - but why would Magento set my files to 666 - making them unreadable by the user? – Liam McArthur Jan 17 '16 at 10:14
  • I'm not aware that Magento sets 666 file permissions but 666 gives read-only to everyone. We don't want to give everyone permissions because of security concerns. Maybe someone from engineering can clear this up. Sorry for the issues you're having. – Steve Johnson Jan 18 '16 at 15:40

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.