zoukankan      html  css  js  c++  java
  • laravel 配置站点域名

    访问一直报404错误

    laravel端:

    default.conf

    server {
            listen       80;
            server_name  api.xxxx.com;
            index index.html index.htm index.php;
            root /alidata/www/default/public;
            
            location / {
                         try_files $uri $uri/ /index.php?$query_string;
            }

            location ~ .*.(php|php5)?$
            {
                #fastcgi_pass  unix:/tmp/php-cgi.sock;
                fastcgi_pass  127.0.0.1:9000;
                fastcgi_index index.php;
                include fastcgi.conf;
            }


            location ~ .*.(gif|jpg|jpeg|png|bmp|swf)$
            {
                expires 30d;
            }


            location ~ .*.(js|css)?$
            {
                expires 1h;
            }
            
            include /alidata/server/nginx/conf/rewrite/default.conf;
            access_log  /alidata/log/nginx/access/default.log;
    }

    web端:

    website.conf

    server {
            listen       80;
            server_name  www.xxxx.com;
            index index.html index.htm;
            root /alidata/www/web;
        
           location / {
                root /alidata/www/web;
                index index.html index.htm;
            }
            location ~ .*.(gif|jpg|jpeg|png|bmp|swf)$
           {
               expires 30d;
           }
           location ~ .*.(js|css)?$
          {
                expires 1h;
           }
        
           #include /alidata/server/nginx/conf/rewrite/default.conf;
           access_log  /alidata/log/nginx/access/website.log;
    }

    https-website.conf:

    server {
            listen        443;
            server_name   www.xxx.com;
            ssl on;
            index index.html index.htm;
            root /alidata/www/web;
            ssl_certificate   /alidata/server/nginx/conf/cert/214463173180944.pem;
                ssl_certificate_key  /alidata/server/nginx/conf/cert/214463173180944.key;
                ssl_session_timeout 5m;
                ssl_ciphers ECDHE-RSA-AES128-GCM-SHA256:ECDHE:ECDH:AES:HIGH:!NULL:!aNULL:!MD5:!ADH:!RC4;
                ssl_protocols TLSv1 TLSv1.1 TLSv1.2;
                ssl_prefer_server_ciphers on;
            location / {
                    root /alidata/www/web;
                index index.html index.htm;
                }
            location ~ .*.(gif|jpg|jpeg|png|bmp|swf)$
            {
                expires 30d;
            }
            location ~ .*.(js|css)?$
            {
                expires 1h;
            }
            
            #include /alidata/server/nginx/conf/rewrite/default.conf;
            access_log  /alidata/log/nginx/access/default.log;
    }

    https-default.conf:

    server {
                listen       443;
                server_name  api.ecaidata.com  superman.ecaidata.com   ;
                ssl on;
                index index.html index.htm index.php;
                root /alidata/www/default/public;
                ssl_certificate   /alidata/server/nginx/conf/cert/214463173180944.pem;
                    ssl_certificate_key  /alidata/server/nginx/conf/cert/214463173180944.key;
                    ssl_session_timeout 5m;
                    ssl_ciphers ECDHE-RSA-AES128-GCM-SHA256:ECDHE:ECDH:AES:HIGH:!NULL:!aNULL:!MD5:!ADH:!RC4;
                    ssl_protocols TLSv1 TLSv1.1 TLSv1.2;
                    ssl_prefer_server_ciphers on;
                location / {
                        try_files $uri $uri/ /index.php?$query_string;
                    }
                location ~ .*.(php|php5)?$
                {
                    #fastcgi_pass  unix:/tmp/php-cgi.sock;
                    fastcgi_pass  127.0.0.1:9000;
                    fastcgi_index index.php;
                    include fastcgi.conf;
                }
                location ~ .*.(gif|jpg|jpeg|png|bmp|swf)$
                {
                    expires 30d;
                }
                location ~ .*.(js|css)?$
                {
                    expires 1h;
                }
                
                include /alidata/server/nginx/conf/rewrite/default.conf;
                access_log  /alidata/log/nginx/access/default.log;
    }

  • 相关阅读:
    有点忙啊
    什么是协程
    HDU 1110 Equipment Box (判断一个大矩形里面能不能放小矩形)
    HDU 1155 Bungee Jumping(物理题,动能公式,弹性势能公式,重力势能公式)
    HDU 1210 Eddy's 洗牌问题(找规律,数学)
    HDU1214 圆桌会议(找规律,数学)
    HDU1215 七夕节(模拟 数学)
    HDU 1216 Assistance Required(暴力打表)
    HDU 1220 Cube(数学,找规律)
    HDU 1221 Rectangle and Circle(判断圆和矩形是不是相交)
  • 原文地址:https://www.cnblogs.com/qq350760546/p/8335207.html
Copyright © 2011-2022 走看看