I was talking to a friend the other day about an error he was getting using his Mac as a development machine. He was using Sites. Seems like the thing to do, right? Not really.
Your OS X system is somewhat pre-configured to run a static Website
with Apache pre-installed and pre-configured. The primary Website
document root, which would be accessed at http://127.0.0.1 (or
http://localhost; which you use is up to you) is found in the
/Library/WebServer/Documents/. You will find a number of index files
in here, due to Apache's ability to negotiate content for
localization, i.e. serving up the same page in different languages.
You may remove these files if you will be focusing on one language.
Comments are Open (4)
Posted at 07:14 AM
Comments
chet
Well, it's not THAT hard to set up multiple sites on a Mac. I mean, I did it. Just check out "Virtual Hosts" in the Apache docs.
Using that and rsync, I manage half a dozen sites in my home directory (e.g., ~/Sites/nogators.com, ~/Sites/miscellaneousheathen.com, etc).
Basically, if you're willing to read some instructions, it's hella simple. :)
Posted by: chet | July 23, 2004 08:26 AM
phnk
Nice trick, thanks ! ;)
Posted by: phnk | July 23, 2004 08:41 AM
Tony
Oh, I'm not saying it's hard. It is easy. I just hadn't done it in about a year, and so forgot about the default setting.
But I don't think it's obvious to the end user that the default root is /Library/WebServer/Documents when you have that /Sites/ folder sitting right there.
Posted by: Tony
|
July 23, 2004 08:47 AM
chet
That I can agree with.
Apple is sort of unsupportive of any sort of real Apache-kung-fu, though, which is frustrating.
Posted by: chet | July 24, 2004 10:14 AM