配备文件:

代码如高:

    http { 
     server { 
     listen          80; 
     server_name     www.domain1.com; 
     access_log      logs/domain1.access.log main; 
     location / { 
     index index.html; 
     root  /var/www/domain1.com/htdocs; 
     } 
     } 

     server { 
     listen          80; 
     server_name     www.domain二.com; 
     access_log      logs/domain二.access.log main; 
     location / { 
     index index.html; 
     root  /var/www/domain两.com/htdocs; 
     }
     }
    }

分析:
只需正在模块内中新删模块;详细的按照你的实践必要往部署。

以上等于nginx多网站要是陈设的具体形式,更多请存眷萤水红IT仄台另外相闭文章!

点赞(5) 打赏

评论列表 共有 0 条评论

暂无评论

微信小程序

微信扫一扫体验

立即
投稿

微信公众账号

微信扫一扫加关注

发表
评论
返回
顶部