server
{
listen 80 default_server;
#listen [::]:80 default_server ipv6only=on;
server_name blog.yangguangwei.xyz;
index index.php index.html index.htm;
root /home/wwwroot/default/blog;

#error_page 404 /404.html;
include enable-php.conf;

location /nginx_status
{
stub_status on;
access_log off;
}

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

location ~ .*\.(js|css)?$
{
expires 12h;
}

location ~ /\.
{
deny all;
}

location / {
try_files $uri $uri/ /index.php?$query_string;
}

location ~ \.php$ {
try_files $uri /index.php =404;
fastcgi_split_path_info ^(.+\.php)(/.+)$;
fastcgi_pass unix:/var/run/php5-fpm.sock;
fastcgi_index index.php;
fastcgi_param SCRIPT_FILENAME $document_root$fastcgi_script_name;
include fastcgi_params;
}

access_log /home/wwwlogs/access.log;
}

lnmp vhost 文件的更多相关文章

  1. centos 6.5 服务器安装 (LNMP ntfs文件支持 PHP-RPM CHROOT沙盒)

    centos 6.5 最小化安装 进入系统 手动开启网卡 #ifconfig eth0        //(默认会自动获得ip) 修改网站配置文件,默认开启 #cd /etc/sysconfig/ne ...

  2. lnmp vhost 虚拟目录配置

    以前常用Windows 很熟悉,lnmp 配置虚拟目录也很简单. 安装完lnmp环境之后,在nginx的配置文件夹下,我采用的方法是复制default.conf 然后重命名为vhost_a.conf ...

  3. vhost文件设置

    #例子<VirtualHost *.82> #设置端口号为82 ServerName localhost #服务器名称 DocumentRoot "d:/Web" #文 ...

  4. lnmp无法删除.user.ini文件的解决办法

    有一次使用命令lnmp vhost del删除虚拟主机后,需要使用ftp或者rm命令删除网站目录,但是却发现网站目录下有个文件.user.ini文件没有自动删除,出现提示rm: cannot remo ...

  5. 记录LNMP环境彻底删除绑定域名及网站文件夹/文件的过程

    lnmp vhost del #删除绑定的域名 chattr -i /home/wwwroot/域名文件夹/.user.ini #解除文件安全限制 rm -rf /home/wwwroot/域名文件夹 ...

  6. LNMP添加、删除虚拟主机及伪静态使用教程

    一般情况下每个虚拟主机就是一个网站,网站一般通过域名进行访问.LNMP 1.2的网站添加过程和LNMP 1.1的基本类似,但是增加了FTP和数据库的创建.LNMP1.2的防跨目录也由原来在php.in ...

  7. lnmp、lamp、lnmpa一键安装包(Updated: 2015-10-25)

    lnmp.lamp.lnmpa一键安装包(Updated: 2015-10-25) 2014-12-26 Posted by yeho 这个脚本是使用shell编写,为了快速在生产环境上部署lnmp/ ...

  8. 图文详解如何快捷搭建LNMP服务环境

    上一篇与大家一起学习了下如何搭建LAMP环境的知识,今天小编再和大家分享下如何快捷地搭建LNMP环境,并搭建起一个网站.Nginx是一个高性能的HTTP和反向代理服务器,也是一个IMAP/POP3/S ...

  9. Vagrant安装完lnmp后,配置linux和windows共享文件并配置虚拟主机访问项目

    虚拟机目录下的Vagrantfile文件是vagrant的配置文件,如果想把虚拟机当作一台服务器,可以通过ip访问,需要修改配置文件进行配置. (1)第一步:打开虚拟机目录下的Vagrantfile文 ...

随机推荐

  1. linux中 /dev/null命令

    /dev/null :代表空设备文件 >  :代表重定向到哪里,例如:echo "123" > /home/123.txt1  :表示stdout标准输出,系统默认值是 ...

  2. DLNg序列模型第二周NLP与词嵌入

    1.使用词嵌入 给了一个命名实体识别的例子,如果两句分别是“orange farmer”和“apple farmer”,由于两种都是比较常见的,那么可以判断主语为人名. 但是如果是榴莲种植员可能就无法 ...

  3. 【LeetCode每天一题】Reverse Linked List(链表反转)

    Reverse a singly linked list. Example:           Input: 1->2->3->4->5->NULL          ...

  4. vmware 12

    下载地址 (linux:https://download3.vmware.com/software/wkst/file/VMware-Workstation-Full-12.1.1-3770994.x ...

  5. Selenium基础知识(九)验证码

    关于Selenium处理验证码总结下: 1.去掉验证码(这个为了测试,去掉可能性不大) 2.万能验证码(让开发给做一个万能验证码,可能性也不大) 3.OCR光学识别,python包Python-tes ...

  6. PyQT5速成教程-4 Qt Designer实战[上]

    本文由 沈庆阳 所有,转载请与作者取得联系! 前言 在前面几节的学习中,我们对PyQt的基本使用.Qt Designer与Python编码的工作流程有了基本的学习.同时也掌握了Qt Designer中 ...

  7. Bukkit插件编程之检测玩家受到的伤害是来自投射类武器还是近身武器

    package com.sklm.lhb.listener; import org.bukkit.entity.Arrow; import org.bukkit.entity.Player; impo ...

  8. leetCode-linkedListCycle判断链表是否有环

    题目 Given a linked list, determine if it has a cycle in it. Follow up: Can you solve it without using ...

  9. django后台的制作

    参考:http://zengestudy.blog.51cto.com/1702365/1902660 http://www.cnblogs.com/fnng/p/3737964.html 实现与后台 ...

  10. C# vs2015单元测试测试资源管理器不显示测试方法

    问题描述:在用VS2015用测试框架NUnit单元测试的时候,测试资源管理器死活不出现测试方法,无法运行单元测试模块 现象如下图: 原因:nunit版本不对应 解决方案:下载nunit3.0及往上的版 ...