How to take control of apache2 Webroot on OS X Mavericks?
I have an apache2 server enabled on my Mac running Mac OS X 10.9 using the default WebRoot
/Library/WebServer/Documents. However, whenever I try to add, edit, or delete a file from that directory in Finder logged onto an Administrator account the files are “Locked” no matter what I attempt, including the
chmod command and Mac’s Change Permission menu inside the “Get Info” window.
I was wondering if anyone knows of a way to allow an Admin or any specific User account to edit the directory without opening up the entire Filesystem to all users.
The easiest way to enable modification of the files within
/Library/WebServer/Documents is to change the permissions from your shell to allow all users of your system to write to the directory.
- Open Terminal.app
Type the following:
sudo chmod -R o+w /Library/WebServer/Documents
This command recursively changes the permissions using sudo.
The process of enabling the default apache installation has been relatively consistent since Apple removed the web sharing option in 10.7?. Here’s a gist with a handful of bits and pieces related to the setup process.
Answered By – Jessedc