Ubuntu – Permissions for apache webroot folder on dev server

Apache2chmodchownpermissionswww

I am a web developer and have Apache setup on my local system for testing.

I keep running into issues with the permissions e.g. unless I chmod any new directories to 777 my IDE cannot write to the files there.

I was hoping there was a way to add myself to the group that has control of the www folder (and any sub folders) so I do not have to chmod the files every time.

Best Answer

I am working on a related issue, but in your case, you could just add yourself to the web group

sudo adduser $USER www-data

replace USER$ with your username of course. www-data is the group used for apache web access.