(编辑:jimmy 日期: 2024/12/25 浏览:2)
Invision Power Board (IPB)是一个论坛程序,基于php+MySQL. 虽然国内大部分都在用discuz,但是国外ipb的用户很多,今天贴出ipb的nginx配置文件。配置如下:
复制代码 代码如下:
server {
access_log off;
error_log logs/bbs.jb51.net-error_log warn;
listen 80;
server_name bbs.jb51.net;
# static file configuration
location ~* .(gif|jpg|jpeg|png|ico|wmv|3gp|avi|mpg|mpeg|mp4|flv|mp3|mid|js|css|wml|swf)$ {
root /data/site/bbs.jb51.net;
expires max;
add_header Pragma public;
add_header Cache-Control "public, must-revalidate, proxy-revalidate";
}
# site configuration
location / {
root /data/site/bbs.jb51.net;
index index.php index.html index.htm;
# IPB configuration
try_files $uri $uri/ /index.php?q=$uri&$args;
}
# php-fpm configuration
location ~ .php$ {
root /data/site/bbs.jb51.net;
try_files $uri =404;
fastcgi_pass unix:/tmp/php5-fpm.sock;//修改成你自己的
fastcgi_index index.php;
fastcgi_param SCRIPT_FILENAME $document_root$fastcgi_script_name;
include fastcgi_params;
fastcgi_buffer_size 128k;
fastcgi_buffers 256 4k;
fastcgi_busy_buffers_size 256k;
fastcgi_temp_file_write_size 256k;
}
}
IPB名词解释:
IPB论坛全称为Invision Power Board(缩写为IPB或IP.Board),是世界上最著名的论坛程式之一,由PHP+MySQL架构,让你毫不费力地创建,管理和促进你的在线论坛,高级直观的,诸如多状态这样的功能允许你只关注于开发你的论坛,而不是被复杂的设置所困扰。