V2EX = way to explore
V2EX 是一个关于分享和探索的地方
Sign Up Now
For Existing Member  Sign In
jimmy
V2EX  ›  macOS

Mac 10.7上配置Apache的目录,想指定到自定义目录一直不成功什么原因?

  •  
  •   jimmy · Aug 8, 2012 · 4711 views
    This topic created in 5019 days ago, the information mentioned may be changed or developed.
    开启Web Share之后只修改了两处:
    httpd.conf里开启了php5支持,Vhost支持。
    然后在extra/httpd-vhost.conf里添加了个虚拟站点,使用sudo apachectl -t检查没问题,但是运行的时候却报403,不知道什么原因造成的,要怎么解决?
    PS: 使用系统自带的路径访问却是正常的……

    不小心发了一篇到MBP节点里,能不能删除啊那篇。
    3 replies    1970-01-01 08:00:00 +08:00
    waredugu
        1
    waredugu  
       Aug 8, 2012
    還是自己編譯nginx吧
    sephrioth
        2
    sephrioth  
       Aug 9, 2012
    MAMP PRO 伺候...
    quake0day
        3
    quake0day  
       Aug 10, 2012
    Create the directory structure
    First set up the directory to hold the files, I call my directory public_beta in my home folder. I normally create a new directory in my home directory for each virtual host, but you could create sub directories under a main web folder.
    $ mkdir ~/public_beta
    Next give the folder and contents permissions of 755 so Apache can read the contents.
    $ chmod -R 755 public_beta
    Change the permissions of $HOME
    Also make sure you home directory has permissions set to 711 so Apache can access your home directory, replace user_name with your login username.
    $ cd /home
    $ chmod 711 user_name
    About   ·   Help   ·   Advertise   ·   Blog   ·   API   ·   FAQ   ·   Solana   ·   1181 Online   Highest 6679   ·     Select Language
    创意工作者们的社区
    World is powered by solitude
    VERSION: 3.9.8.5 · 32ms · UTC 17:43 · PVG 01:43 · LAX 10:43 · JFK 13:43
    ♥ Do have faith in what you're doing.