nginx 配置 server
server{
listen 80;
server_name test.eoews.cn;
#项目文件的路径
root "D:/developer/study/PHPTutorial/WWW/project/eoews";
#默认寻找打开文件
location / {
#默认打开的文件
index index.html index.htm index.php l.php;
#打开目录浏览功能
autoindex off;
#重写机制
if (!-e $request_filename) {
rewrite ^/(.*)$ /index.php/$1 last;
break;
}
}
#将服务器错误重定向到指定的静态页面中
error_page 500 502 503 504 D:/developer/study/PHPTutorial/nginx/html/50x.html; location = /50x.html {
root D:/developer/study/PHPTutorial/nginx/html;
} location ~ \.php(.*)$ {
fastcgi_pass 127.0.0.1:9000;
fastcgi_index index.php;
fastcgi_split_path_info ^((?U).+\.php)(/?.+)$;
fastcgi_param SCRIPT_FILENAME $document_root$fastcgi_script_name;
fastcgi_param PATH_INFO $fastcgi_path_info;
fastcgi_param PATH_TRANSLATED $document_root$fastcgi_path_info;
include fastcgi_params;
}
}
nginx 配置 server的更多相关文章
- thinkphp nginx配置
安装和配置: http://www.cnblogs.com/Bonker/p/4252588.html spawn-fcgi 要先安装和启动:(已过时) sudo spawn-fcgi -a -u ...
- thinkphp的nginx配置
thinkphp的nginx配置 server { listen 80; server_name www.abc.com; #charset utf-8; access_log /var/www/ww ...
- Nginx配置域名转发实例
域名:cps.45wan.com 所在阿里云主机:123.35.9.12 45wan没有在阿里云备案 67wan已经在阿里云备案 阿里云主机(假如123.35.9.12)上原来的nginx配置: ...
- Nginx配置http跳转https访问
Nginx强制http跳转https访问有以下几个方法 nginx的rewrite方法 可以把所有的HTTP请求通过rewrite重写到HTTPS上 配置 方法一 server{ listen ; s ...
- 用rewrite把旧域名直接跳转到新域名的nginx配置
用rewrite把旧域名直接跳转到新域名的nginx配置 把下面代码保存到daziran.com.conf 放在nginx配置目录下 /etc/nginx/conf.d/ #把旧域名zdz8207直接 ...
- nginx配置二级域名
我在我的服务器上面跑了两个node应用程序,分别一个端口2368跑的是ghost博客,一个端口8000跑的是我的demo程序.想要一级域名zhangruojun.com用来访问博客,二级域名demo. ...
- django wsgi nginx 配置
""" WSGI config for HelloWorld project. It exposes the WSGI callable as a module-leve ...
- Nginx配置https双向认证
1. 前期的准备工作: 安装openssl和nginx的https模块 cd ~/ mkdir ssl cd ssl mkdir demoCA cd demoCA mkdir newcert ...
- Nginx配置Web项目(多页面应用,单页面应用)
目前前端项目 可分两种: 多页面应用,单页面应用. 单页面应用 入口是一个html文件,页面路由由js控制,动态往html页面插入DOM. 多页面应用 是由多个html文件组成,浏览器访问的是对应服务 ...
随机推荐
- secruity
security3.x <?xml version="1.0" encoding="UTF-8"?> <beans:beans xmlns=& ...
- c# 拉姆达表达式实现List去重
c# 拉姆达表达式实现List去重 var list = studentlist.OrderByDescending(a => a.CreateDate).ToList(); Console.W ...
- Python元组与字符串操作(8)——三数排序多种实现
练习 依次接收用户输入的3个数,排序后打印 1.转换int后,判断大小排序,使用分支结构完成 num1 = [] for i in range(3): num1.append(int(input('& ...
- URL处理----拼接和编码
ps:浪了好几周,我的锅... 前几天想爬取一个用户网站自动创建每个用户的资料方便注册一些账号,想写一个通用点的爬虫程序爬取只要配置一些爬取规则.爬取深度就ok,避免代码改动,由于时间关系只完成的个半 ...
- 201871010111-刘佳华《面向对象程序设计(java)》第二周学习总结
201871010111-刘佳华<面向对象程序设计(java)>第二周学习总结 项目 内容 这个作业属于哪个课程 <https://www.cnblogs.com/nwnu-daiz ...
- Linux SSH建立连接过程分析
https://blog.csdn.net/qwertyupoiuytr/article/details/71213463 SSH建立连接的过程主要分为下面几个阶段: SSH协议版本协商阶段.SSH目 ...
- Graph Embedding Review:Graph Neural Network(GNN)综述
作者简介: 吴天龙 香侬科技researcher 公众号(suanfarensheng) 导言 图(graph)是一个非常常用的数据结构,现实世界中很多很多任务可以描述为图问题,比如社交网络,蛋白体 ...
- pycharm访问mysql数据库
不需要像eclipse那样添加驱动包,在pycharm里面下载一个pymysql包即可. 然后链接自己电脑的mysql并进行访问即可. 源码如下(参考博客:https://blog.csdn.net/ ...
- 组件注册-自定义TypeFilter指定过滤规则
组件注册-自定义TypeFilter指定过滤规则 4.1 FilterType.ANNOTATION 按照注解方式 4.2 FilterType.ASSIGNABLE_TYPE 按照给定的类型 @Co ...
- nwjs-简介
nwjs是基于nodejs的,它支持nodejs所有的api,主要用于跨平台轻量级桌面应用开发,运行环境包括32位和64位的Window.Linux和Mac OS nwjs是在英特尔开源技术中心创建的 ...