我想配置用 ai.test.com访问, 不要用ai.test.com/app/ai
server {
server_name ai.test.com;
listen 80;
access_log off;
proxy_buffering off;
root /var/www/html/webmanai/public;
location ^~ / {
proxy_set_header X-Real-IP $remote_addr;
proxy_set_header Host $host;
proxy_set_header X-Forwarded-Proto $scheme;
proxy_http_version 1.1;
proxy_set_header Connection "";
proxy_pass http://127.0.0.1:8787/app/ai;
}
}
https://www.workerman.net/app/view/ai
常见问题里有写,不用动nginx配置,webman写个路由就行了
在 config/route.php中增加如下路由配置
执行 php start.php reload