hostease主机优惠

Mediawiki中文技术论坛

 找回密码
 注册

QQ登录

只需一步,快速开始

查看: 4431|回复: 1

RHEL 5.4 + Nginx + Mediawiki

[复制链接]
发表于 2011-9-4 14:32:53 | 显示全部楼层 |阅读模式
Godaddy主机最新优惠码
RHEL 5.4 + Nginx + Mediawiki

# Virtual wiki.atyu30.com
# Author atyu30
# Date: 2011/08/31

## uname -r -m -o
#2.6.18-194.el5 x86_64 GNU/Linux
## nginx -v
#nginx: nginx version: nginx/1.1.1
# Change 2011/09/02
# MediaWiki-1.17.0 php-fpm Nginx Sphinx
server {
        listen       443;
        #listen       80;
        server_name  wiki.atyu30.com;
        charset utf-8;

        fastcgi_param        HTTPS                $fastcgi_https;
        location / {
            root   /var/www/mediawiki-1.16.4;
            index  index.php index.html index.htm;
            #将请求的不存在文件重写到index.php
            try_files  $uri $uri/ /index.php;
          
                if (!-f $request_filename){
                                 rewrite ^/([^?]*)(?:\?(.*))? /index.php?title=$1&$2 last;
                            rewrite (.*) /index.php;
                }
        }


        location ~ \.php$ {
            root           /var/www/mediawiki-1.16.4;
            fastcgi_pass   127.0.0.1:9000;
            fastcgi_index  index.php;
            fastcgi_intercept_errors on;
            fastcgi_param  SCRIPT_FILENAME  $document_root$fastcgi_script_name;
            include        fastcgi_params;
            client_max_body_size        20m;
        }

        ssl                  on;
        ssl_certificate      /etc/pki/tls/certs/server.crt;
        ssl_certificate_key  /etc/pki/tls/private/server.key;
        ssl_session_timeout  5m;
        ssl_protocols  SSLv2 SSLv3 TLSv1;
        ssl_ciphers  ALL:!ADH:!EXPORT56:RC4+RSA:+HIGH:+MEDIUM:+LOW:+SSLv2:+EXP;
        ssl_prefer_server_ciphers   on;

}

        map $scheme $fastcgi_https {
            default off;
            https on;
        }
回复

使用道具 举报

发表于 2011-9-11 05:17:49 | 显示全部楼层
BlueHost主机优惠码
看后感悟了点,收下了













点评

不知道你有什么感悟  发表于 2011-9-24 17:18
回复 支持 反对

使用道具 举报

您需要登录后才可以回帖 登录 | 注册

本版积分规则

BlueHost美国主机优惠码

Archiver|手机版|小黑屋|Mediawiki中文技术论坛

GMT+8, 2024-4-27 01:20 , Processed in 0.036425 second(s), 16 queries .

Powered by Discuz! X3.4

Copyright © 2001-2024, Tencent Cloud.

快速回复 返回顶部 返回列表