Cool~
迟交的作业哈...
我给你复制黏贴过来.
server {
listen kohana.local:8080;
server_name kohana.local;
access_log /var/log/nginx/kohana.access.log;
# define server root path
set $root_path /home/icyleaf/php/kohana;
location / {
root $root_path;
index index.php index.html index.htm;
if (!-e $request_filename) {
rewrite ^/(.*)$ /index.php?kohana_uri=/$1 last;
}
}
# pass the PHP scripts to FastCGI server listening on 127.0.0.1:9000
#
location ~ \.php$ {
root $root_path;
fastcgi_pass 127.0.0.1:9000;
fastcgi_index index.php;
fastcgi_param SCRIPT_FILENAME $root_path$fastcgi_script_name;
include fastcgi_params;
}
}
发表讨论