一个域名如何配置两个laravel 项目
本文最后更新于5 天前

有些情况下只能申请到一个域名比如a.com,当需要运行两个laravel项目时我们可以使用a.com/sub_website 访问第二个laravel项目a.com 的nginx配置添加如下配置:

location ^~ /sub_website{
        alias /data/wwwroot/****/public;
        if (!-e $request_filename) { rewrite ^ /sub_website/index.php last; }
            index index.php index.html;
            location ~ \.php$ {
                if (!-f $request_filename) {
                        return 404;
                }
                 fastcgi_pass        unix:/dev/shm/php-cgi.sock;
                 fastcgi_index       index.php;
                 fastcgi_param       SCRIPT_FILENAME $request_filename;
                 include             fastcgi_params;
        }

  }

 



扫码关注,及时关注技术动态


暂无评论

发送评论 编辑评论


				
|´・ω・)ノ
ヾ(≧∇≦*)ゝ
(☆ω☆)
(╯‵□′)╯︵┴─┴
 ̄﹃ ̄
(/ω\)
∠( ᐛ 」∠)_
(๑•̀ㅁ•́ฅ)
→_→
୧(๑•̀⌄•́๑)૭
٩(ˊᗜˋ*)و
(ノ°ο°)ノ
(´இ皿இ`)
⌇●﹏●⌇
(ฅ´ω`ฅ)
(╯°A°)╯︵○○○
φ( ̄∇ ̄o)
ヾ(´・ ・`。)ノ"
( ง ᵒ̌皿ᵒ̌)ง⁼³₌₃
(ó﹏ò。)
Σ(っ °Д °;)っ
( ,,´・ω・)ノ"(´っω・`。)
╮(╯▽╰)╭
o(*////▽////*)q
>﹏<
( ๑´•ω•) "(ㆆᴗㆆ)
😂
😀
😅
😊
🙂
🙃
😌
😍
😘
😜
😝
😏
😒
🙄
😳
😡
😔
😫
😱
😭
💩
👻
🙌
🖕
👍
👫
👬
👭
🌚
🌝
🙈
💊
😶
🙏
🍦
🍉
😣
Source: github.com/k4yt3x/flowerhd
颜文字
Emoji
小恐龙
花!
上一篇
下一篇