Vagrant 403 Forbidden

前端 未结 4 2232
一整个雨季
一整个雨季 2021-02-14 06:17

I\'ve been running Vagrant successfully for about a week. Last night I ran vagrant reload and now I can no longer access my sites.

  • VirtualBox version 4.2.16
4条回答
  •  抹茶落季
    2021-02-14 06:51

    This is solved and in the end came down to some very simple things.

    • Use "Require All granted" instead of "Allow from All"
    • Put each websites' content at the same level namely /vagrant/Sites/default, /vagrant/Sites/test, /vagrant/Sites/real-site
    • Add .conf extension to vhost names such as test.conf and real-site.conf
    • Add AllowOverride All to vhosts to respect sites' .htaccess file (I realize that was in my original post, it got lost as I tried to solve this)

    All very basic things that eluded me for a better part of a week. I hope this can help someone else.

提交回复
热议问题