Mac Server Series: Hosting Multiple Web Sites on a Single Mac


Welcome to the site. Our most popular posts are a series of video tutorials on How To Use Your Mac As A Server. We also answer your Mac questions. Just Ask FMB Feel free subscribe to our RSS feed. Thanks for visiting!

Image
In this Mac Server Series screencast I explain how to host multiple web sites (domains) on a single Mac. In Apache parlance this is called setting up “virtual hosts”. Just as FreeMacBlog.com, FreeMacWare.com, FreeMacUnix.com, etc. all run on a single Mac at Macminicolo.net, with these instructions you can do the same.

Watch it here: How to Host Multiple Web Sites on a Single Mac

Show Notes:


29 Responses to “Mac Server Series: Hosting Multiple Web Sites on a Single Mac”

  1. Joe Says:

    Glad to see you are back!

  2. Jesper Says:

    http://www.macminicolo.net/videos/ServerVideo6.mov dos not exist

  3. Brian Says:

    Jesper, it is currently propagating to multiple servers. Until that happens, just refresh the page a few times in your browser and it will come up.

  4. rob Says:

    Glad to see you back Sir….. You out did yourself on this video.. good job… Hey do you think when you have time to do a video on setting up a file server on the mac?

  5. Matthieu Says:

    I second Rob for the file server video. Would be glad to see it here.

  6. RKM Says:

    @Rob and Matthieu, a file server video is a good idea. What sort of file server are you looking for? Turning on FTP or Windows file sharing is a matter of checking the box in System Preferences Sharing, but I assume you must be looking for something more than this.

  7. aquaibm Says:

    Good job!Men,just keep going.

  8. Kirk Says:

    ‘…it is currently propagating to multiple servers.’

    How do you host the video on multiple servers and have one URL for all of them ?

  9. rob Says:

    RKM,

    Yeah i was looking to see how you can setup a (5) users with one logon password, but have them see only the folders they need to see.

    So I guess all of the users folders would be in one single dir.

  10. Brian Says:

    Kirk, we use a great service called Pure Static to serve up these videos.

    http://www.purestatic.com

  11. RKM Says:

    rob: I get you now. That sort of server setup sounds like a good topic for a tutorial. I’ll look into it.

  12. Jim Says:

    Just heard about your site from Mac Daily News - thanks much for your time & effort! A practical issue: not being a web ace (understatement - I’m having to learn this stuff from zero), I nevertheless need to build a site. Given the streaming nature of your video, Safari won’t allow zooming in, and the text you type in your video is too small to see on my monitor. Is it possible to simply download your videos so I can play them full screen on one monitor while typing on another? I don’t see a link for downloading… Thanks.

  13. Ken Says:

    This doesn’t work. I did everything just as it is in the video, but it didn’t work as shown. I got a screen that said Forbidden.

    What is the missing step?

  14. RKM Says:

    Jim: Thanks for your comment. To download the video, hold the Option key as you click the link. It will begin to download the video. Once downloaded, you can zoom it in Quicktime.

  15. RKM Says:

    Ken, it sounds like you have a permissions issue on one of the files. Assuming you made an index.html file, click on that file and choose Get Information from the file menu. Then under Ownership & Permissions click Details and make sure under Group Access it says “Read Only” and under Others it says “Read Only”. If it doesn’t work, let me know. The same thing may be necessary for the folder that contains index.html.

  16. DLB Says:

    I have the same permissions problem after following the video. I get the 403 Forbidden error with trying to navigate to the websites I created. The Permissionss for Group Access and Others is “Read Only”. Any assistance would be appreciated.

  17. Administrator Says:

    DLB (and Ken): Could you give more details about your setup? Where is your index.html file located?

  18. DLB Says:

    I followed the video step by step. It is in the root under the www directory. All the permissions are set the way you specified earlier. I have an iMac and a Macbook and I get the same results on both.

    Thanks,
    DLB

  19. andy Says:

    hi soory to be a newbee but im buying my first mac its the imac 24″
    i would like to set up a web and file server i have just got in to this web site idea do i need to buy a domian name or can i use a free one i dont mind paying if i got one how can i set it up

    if some one can help me set this up i will happley pay for help

    thanks andy sorry if this sounds too newbee

  20. rob Says:

    thanks RKM.. I hope you can get a video out about the file server..

    rob

  21. Chris Says:

    Awesome! I have been looking for something like this for a while now! Keep them coming.

    Chris

  22. Alojamento Says:

    Great video! Just what I was looking for thanks!

  23. Dave Says:

    Congratulations on the video, it is excellent. I do however have a problem with permissions. I cannot alter the hosts file. I am using BBEdit Lite (Smultron is at 10.4, I’m still 10.3) and as soon as I attempt an edit I’m told the file belongs to root. I’m logged in as “Admin”. I have tried to log in as root (setting the root account in NetInfoManager as per the Apple help file) but don’t get the “Other” account in the log in screen. I have the horrible feeling that I’m missing the obvious but am at a loss as to what it is. Do you have any pointers? If it helps I tried first on a local machine (10.3) as well as my remote mini (minimaccolo) each time with the same result - can’t log in as root!

  24. Mal Says:

    Thanks for all the information.

    I was wondering if the security as standard with OSX and apche is enough when hosting from my home imac or would it be wise to alter the configuration of apache in some way to make it more secure, or even get a dedicated mac mini for the job and palce it out side my home network?
    I sometimes get strange “Get” requests in the access logs, mostly from china for some reason. Or am I just worrying over nothing?

  25. brian Says:

    What a lifesaver! I’ve been trying for over a week to make virtual hosts work. I tried the Apache instructions and dozens of others. Nothing worked until I watched Richard’s video, and then I had it up and running in ten minutes!!! I shared this with my friends in the Macintosh group over at Flickr (http://www.flickr.com/groups/macintosh/discuss/72157600152195277/#comment72157600171029227).

    Now all I have to do is come up with some content for my three sites…

  26. Richard Says:

    brian, thanks for the nice comment about the video. I’m glad it was helpful.

  27. Hitesh Says:

    amazing video got the localhost mysite myothersite and mythirdsite up in no time

    But in the real world, I have 2 domains AND I AM pointing both of them to my ip address, then changed httpd.conf file settings, but nothing happened, Please tell me in the real world is there something else to be done ?
    Thankz

  28. Mark Says:

    This is a simple question, but if I don’t want to register multiple domain names, is there still a way to host multiple sites on my mac mini?

  29. Mac Server Series: Configure Two IP Addresses On One Mac -- ministats.com Says:

    […] already showed you how to host multiple web sites on one Mac, but that tutorial assumes you want them all to have the same ip address. Sometimes, you’ll […]

Leave a Reply