1

I have setup a PhalconPHP project on an AWS EC2 instance. To get thinks working I gave the cache directory 777 permissions. I realise this is bad practice - what would be the correct permissions for a cache directory on a webserver?

I presume it must specific to the user the httpd service is running as (the output from the method given by the top voted answer to this question implies that the user is apache). But I obviously want to keep my ec2-user having write access to the directory (I don't want to have to use sudo the whole time).

What would be the correct set of permissions for the directory? I have a www group that ec2-user is part of, should apache be added to that?

  • 1
    Do 700 for everything and do an ACL for the other user. There's no sense in giving an entire group access to just give access to one other user. – Bratchley Aug 1 '16 at 11:51

Your Answer

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

Browse other questions tagged or ask your own question.