# 代碼庫
git:[https://git.100tal.com/chanpinzhongxin\_xueersiqingke\_qkother/qingke\_course](https://git.100tal.com/chanpinzhongxin_xueersiqingke_qkother/qingke_course)
# nginx配置:
server {
listen 80;
server\_name my.rpc.course.txbapp.com;
root /Users/zouyang/code/qingke\_course/public;
index index.html index.htm index.php;
#allow 10.45.149.50;
#include Configs/allow-ip.conf;
location / {
try\_files $uri $uri/ /index.php?$query\_string;
include fastcgi.conf;
}
location ~ \\.php$ {
fastcgi\_pass 127.0.0.1:9000;
fastcgi\_index index.php;
fastcgi\_param SCRIPT\_FILENAME $document\_root$fastcgi\_script\_name;
include fastcgi\_params;
}
}
# 框架分層:
路由 App->Rpc->map.php
參數檢校層 App->Rpc
業務邏輯層 App->Logic
數據緩存層 App->Repos
Models App->Models
(**不允許跨層寫代碼 ** )
# rpc調試
/api/rpc?callback=demo.getlist&id=1&name=adfdf