doushai4890 2014-12-09 17:37
浏览 153
已采纳

如何将Yii添加到Laravel Homestead的流浪盒中?

i'm using Yii instead of Laravel for a project. I love Homestead, and Yii is running fine in it and hosted just fine, aside from using command lines like "yii migrate", which needs to be run from within vagrant ssh.

how do i add yii to my homestead box's config? i haven't dabbled much with vagrant other than homestead, but i feel like this should be pretty simple.

thank you!

  • 写回答

1条回答 默认 最新

  • doulei2100 2014-12-09 17:55
    关注

    You should be able to just add another site to your homestead.yaml file. From the Laravel docs (http://laravel.com/docs/4.2/homestead):

    Configure Your Nginx Sites

    Not familiar with Nginx? No problem. The sites property allows you to easily map a "domain" to a folder on your Homestead environment. A sample site configuration is included in the Homestead.yaml file. Again, you may add as many sites to your Homestead environment as necessary. Homestead can serve as a convenient, virtualized environment for every Laravel project you are working on!

    You can make any Homestead site use HHVM by setting the hhvm option to true:

    sites:
        - map: homestead.app
          to: /home/vagrant/Code/Laravel/public
        - map: myapp2.com
          to: /home/vagrant/Code/myapp2/public
          hhvm: true
    
    本回答被题主选为最佳回答 , 对您是否有帮助呢?
    评论

报告相同问题?