nginx vhost配置
server
{
listen 80;
server_name crsdemo.my;
index index.html index.htm index.php default.html default.htm default.php;
root /home/xss/www7/crs/public/admin; rewrite_log on; location ~* ^/(upload|static)/.*\.(php|php5)$
{
rewrite "^/(.*)$" /static/405.html break;
} if (!-f $request_filename) {
rewrite ^/$ /index.php last;
rewrite ^/(?!(index\.php|upload|static))(.*)$ /index.php?$1$2 last;
rewrite ^/index.php(.*)$ /index.php?$1 last;
} location ~ \.php$ {
fastcgi_pass 127.0.0.1:9007;
fastcgi_index index.php;
include fastcgi.conf;
} access_log /home/xss/www/log/gjsgzgzpg.log;
error_log /home/xss/www/log/gjsgzgzpg.log notice;
error_log /home/xss/www/log/gjsgzgzpg.log;
}
nginx vhost配置的更多相关文章
- lnmp集成环境tp nginx vhost配置
server { listen 80; server_name xxx; charset utf-8; root /home/wwwroot/axxx/public; index index.html ...
- 在Nginx上配置多个站点
有时候你想在一台服务器上为不同的域名运行不同的站点.比如www.siteA.com作为博客,www.siteB.com作为论坛.你可以把两个域名的IP都解析到你的服务器上,但是没法在Nginx的根目录 ...
- nginx常用配置系列-虚拟主机
本来准备详尽的出一份nginx配置讲解,但nginx功能配置繁多,平常使用中使用最多的一般有: 1. 虚拟主机配置 2. HTTPS配置 3. 静态资源处理 4. 反向代理 ============= ...
- linux下安装nginx与配置
linux系统为Centos 64位 第一步:从http://nginx.org/download/上下载相应的版本(或者wget http://nginx.org/download/nginx-1. ...
- linux-centerOs6.8安装nginx与配置
一:安装nginx 1.安装gcc(命令:yum install gcc)备注:可以输入gcc -v查询版本信息,查看是否自带安装 2.安装pcre(命令:yum install pcre-devel ...
- 【第六课】Nginx常用配置下详解
目录 Nginx常用配置下详解 1.Nginx虚拟主机 2.部署wordpress开源博客 3.部署discuz开源论坛 4.域名重定向 5.Nginx用户认证 6.Nginx访问日志配置 7.Ngi ...
- Nginx SSL配置
一.SSL 原理 ① 客户端( 浏览器 )发送一个 https 请求给服务器② 服务器要有一套证书,其实就是公钥和私钥,这套证书可以自己生成,也可以向组织申请,服务器会把公钥传输给客户端③ 客户端收到 ...
- Nginx(一):linux下安装nginx与配置
linux系统为Centos 64位 准备目录 [root@instance-3lm099to ~]# mkdir /usr/local/nginx [root@instance-3lm099to ~ ...
- 阿里云centOS7.4 nginx: [emerg] "server" directive is not allowed here in /etc/nginx/vhost/xxxxxx.conf:2
里云centOS7.4配置多个站点遇到的问题nginx: [emerg] "server" directive is not allowed here in /etc/nginx/ ...
随机推荐
- c++ 动态库的加载
转载:https://blog.csdn.net/ztq_12345/article/details/99677769 使用ide是vs, 使用Windows.h下的3个函数对动态库进行加载第一个:H ...
- matlab中nargin函数输入参数数目
来源:https://ww2.mathworks.cn/help/matlab/ref/nargin.html?searchHighlight=nargin&s_tid=doc_srchtit ...
- linux下各种骚操作
(备注:不定时更新) 1. ctrl+l 清屏快捷键,相当于clear 2. !+命令开头部分 执行最近执行的此条命令 ### 如!vi 编辑上一次用vi打开的文件, 3. echo $$ ...
- java进阶(26)--ForEach
JDK5.0后新特性 一.普通for循环
- 搭建go-stress-testing压力测试
参考地址:https://github.com/link1st/go-stress-testing安装golang环境 yum install -y golang 下载软件包 wget -q http ...
- DDOS、CC、sql注入,跨站攻击防御方法
web安全常见攻击解读--DDos.cc.sql注入.xss.CSRF 一,DDos https://www.cnblogs.com/sochishun/p/7081739.html#4111858 ...
- 强大的table组件-antd pro table
概述 antd pro table antd pro table 的主要部分 表格显示的配置(绿色框内) 检索的配置(红色框内) 是否显示检索部分 检索的内容是如何生效的 工具栏的配置(黄色框内) 表 ...
- scrapy LinkExtractors
class scrapy.linkextractors.LinkExtractor Link Extractors 的目的很简单: 提取链接。 每个LinkExtractor有唯一的公共方法是 ext ...
- 爬虫学习之-scrapy交互式命令 scrapy查看页面
scrapy shell https:///www.baidu.com 会启动爬虫请求网页 view(response) 会在浏览器打开请求到的临时文件 response.xpath("/ ...
- 【事件中心 Azure Event Hub】使用Logstash消费EventHub中的event时遇见的几种异常(TimeoutException, ReceiverDisconnectedException)
问题描述 使用EFK(Elasticsearch, Fluentd and Kibana)在收集日志的解决方案中, 可以先把日志发送到EventHub中,然后通过Logstash消费EventHub中 ...