64 lines
1.4 KiB
Text
64 lines
1.4 KiB
Text
|
|
server {
|
||
|
|
listen 80;
|
||
|
|
server_name _;
|
||
|
|
|
||
|
|
# API routes
|
||
|
|
location /console/api {
|
||
|
|
proxy_pass http://dify-api:5001;
|
||
|
|
include /etc/nginx/proxy.conf;
|
||
|
|
}
|
||
|
|
|
||
|
|
location /api {
|
||
|
|
proxy_pass http://dify-api:5001;
|
||
|
|
include /etc/nginx/proxy.conf;
|
||
|
|
}
|
||
|
|
|
||
|
|
location /v1 {
|
||
|
|
proxy_pass http://dify-api:5001;
|
||
|
|
include /etc/nginx/proxy.conf;
|
||
|
|
}
|
||
|
|
|
||
|
|
location /files {
|
||
|
|
proxy_pass http://dify-api:5001;
|
||
|
|
include /etc/nginx/proxy.conf;
|
||
|
|
}
|
||
|
|
|
||
|
|
location /mcp {
|
||
|
|
proxy_pass http://dify-api:5001;
|
||
|
|
include /etc/nginx/proxy.conf;
|
||
|
|
}
|
||
|
|
|
||
|
|
location /triggers {
|
||
|
|
proxy_pass http://dify-api:5001;
|
||
|
|
include /etc/nginx/proxy.conf;
|
||
|
|
}
|
||
|
|
|
||
|
|
# WebSocket
|
||
|
|
location /socket.io/ {
|
||
|
|
proxy_pass http://dify-api:5001;
|
||
|
|
include /etc/nginx/proxy.conf;
|
||
|
|
proxy_set_header Upgrade $http_upgrade;
|
||
|
|
proxy_set_header Connection "upgrade";
|
||
|
|
proxy_cache_bypass $http_upgrade;
|
||
|
|
}
|
||
|
|
|
||
|
|
# Explore / shared apps
|
||
|
|
location /explore {
|
||
|
|
proxy_pass http://dify-web:3000;
|
||
|
|
include /etc/nginx/proxy.conf;
|
||
|
|
}
|
||
|
|
|
||
|
|
# Plugin endpoints
|
||
|
|
location /e/ {
|
||
|
|
proxy_pass http://dify-plugin-daemon:5002;
|
||
|
|
proxy_set_header Dify-Hook-Url $scheme://$host$request_uri;
|
||
|
|
include /etc/nginx/proxy.conf;
|
||
|
|
}
|
||
|
|
|
||
|
|
# Web frontend (Next.js)
|
||
|
|
location / {
|
||
|
|
proxy_pass http://dify-web:3000;
|
||
|
|
include /etc/nginx/proxy.conf;
|
||
|
|
}
|
||
|
|
}
|