Got 404 only on Explore tab #7630

Closed
opened 2026-02-21 18:21:34 -05:00 by yindo · 4 comments
Owner

Originally created by @kurokobo on GitHub (Jan 9, 2025).

Self Checks

  • This is only for bug report, if you would like to ask a question, please head to Discussions.
  • I have searched for existing issues search for existing issues, including closed ones.
  • I confirm that I am using English to submit this report (我已阅读并同意 Language Policy).
  • [FOR CHINESE USERS] 请务必使用英文提交 Issue,否则会被关闭。谢谢!:)
  • Please do not modify this template :) and fill in all the required fields.

Dify version

1.0.0-beta.1

Cloud or Self Hosted

Self Hosted (Docker)

Steps to reproduce

  1. Deploy 1.0.0-beta.1
  2. Initialize instance and log in as a owner
  3. Open Explore tab

✔️ Expected Behavior

No apps are displayed without any error

Actual Behavior

image

Other pages (Studio, Knowledge, Tools, Plugin) are fine:
image

Originally created by @kurokobo on GitHub (Jan 9, 2025). ### Self Checks - [X] This is only for bug report, if you would like to ask a question, please head to [Discussions](https://github.com/langgenius/dify/discussions/categories/general). - [X] I have searched for existing issues [search for existing issues](https://github.com/langgenius/dify/issues), including closed ones. - [X] I confirm that I am using English to submit this report (我已阅读并同意 [Language Policy](https://github.com/langgenius/dify/issues/1542)). - [X] [FOR CHINESE USERS] 请务必使用英文提交 Issue,否则会被关闭。谢谢!:) - [X] Please do not modify this template :) and fill in all the required fields. ### Dify version 1.0.0-beta.1 ### Cloud or Self Hosted Self Hosted (Docker) ### Steps to reproduce 1. Deploy 1.0.0-beta.1 2. Initialize instance and log in as a owner 3. Open `Explore` tab ### ✔️ Expected Behavior No apps are displayed without any error ### ❌ Actual Behavior ![image](https://github.com/user-attachments/assets/eaaae85d-1765-46cf-8e00-fdd1587efaa1) Other pages (Studio, Knowledge, Tools, Plugin) are fine: ![image](https://github.com/user-attachments/assets/d0fdbccc-e454-4f86-9e35-2bce1efa3c3b)
yindo added the 🐞 bug label 2026-02-21 18:21:34 -05:00
yindo closed this issue 2026-02-21 18:21:34 -05:00
Author
Owner

@kurokobo commented on GitHub (Jan 9, 2025):

@Yeuoly
The location is determined by prefix matching. Since /explore matches /e, it seems to be routed to the plugin daemon.
https://github.com/langgenius/dify/blob/28edbbac0b4f3da7403de1f00b6cf0a8e4c0e24b/docker/nginx/conf.d/default.conf.template#L27-L30

> docker compose logs plugin_daemon
...
plugin_daemon-1  | [GIN] 2025/01/09 - 15:55:17 | 404 |         469ns |      172.19.0.1 | GET      "/explore/installed/ba4b2606-c9d0-48e7-86f0-4049b171e1b7"
plugin_daemon-1  | [GIN] 2025/01/09 - 16:09:19 | 404 |         723ns |      172.19.0.1 | GET      "/explore/apps?_rsc=ov8g6"
plugin_daemon-1  | [GIN] 2025/01/09 - 16:09:19 | 404 |         765ns |      172.19.0.1 | GET      "/explore/apps"
plugin_daemon-1  | [GIN] 2025/01/09 - 16:09:22 | 404 |         605ns |      172.19.0.1 | GET      "/explore/apps?_rsc=ov8g6"
...
@kurokobo commented on GitHub (Jan 9, 2025): @Yeuoly The `location` is determined by prefix matching. Since `/explore` matches `/e`, it seems to be routed to the plugin daemon. https://github.com/langgenius/dify/blob/28edbbac0b4f3da7403de1f00b6cf0a8e4c0e24b/docker/nginx/conf.d/default.conf.template#L27-L30 ```bash > docker compose logs plugin_daemon ... plugin_daemon-1 | [GIN] 2025/01/09 - 15:55:17 | 404 | 469ns | 172.19.0.1 | GET "/explore/installed/ba4b2606-c9d0-48e7-86f0-4049b171e1b7" plugin_daemon-1 | [GIN] 2025/01/09 - 16:09:19 | 404 | 723ns | 172.19.0.1 | GET "/explore/apps?_rsc=ov8g6" plugin_daemon-1 | [GIN] 2025/01/09 - 16:09:19 | 404 | 765ns | 172.19.0.1 | GET "/explore/apps" plugin_daemon-1 | [GIN] 2025/01/09 - 16:09:22 | 404 | 605ns | 172.19.0.1 | GET "/explore/apps?_rsc=ov8g6" ... ```
Author
Owner

@dosubot[bot] commented on GitHub (Jan 9, 2025):

A similar issue was previously reported and closed: Creating an app from a Template causes a 404 error [SELF_HOSTED]. This issue was resolved by a pull request that fixed an error related to importing Explore Apps [1].

In your case, the 404 error on the Explore tab seems to be caused by the Nginx configuration, where requests to /explore are being routed to the plugin_daemon service instead of the web service. This is due to the prefix matching in the Nginx configuration, where /explore matches /e and is thus directed to the plugin_daemon service, which does not handle these routes properly.

To resolve this, you may need to adjust the Nginx configuration to ensure that requests to /explore are correctly routed to the web service instead of the plugin_daemon. You can modify the Nginx configuration file to add a specific location block for /explore that routes requests to the appropriate service.

To continue talking to Dosu, mention @dosu.


Help Dosu learn! Give it feedback: Great Response | Irrelevant Answer | Incorrect Sources | Too Verbose | Hallucination | Other

@dosubot[bot] commented on GitHub (Jan 9, 2025): <!-- Answer --> A similar issue was previously reported and closed: [Creating an app from a Template causes a 404 error [SELF_HOSTED]](https://github.com/langgenius/dify/issues/11082). This issue was resolved by a pull request that fixed an error related to importing Explore Apps <sup>[[1]](https://github.com/langgenius/dify/issues/11082)</sup>. In your case, the 404 error on the Explore tab seems to be caused by the Nginx configuration, where requests to `/explore` are being routed to the `plugin_daemon` service instead of the `web` service. This is due to the prefix matching in the Nginx configuration, where `/explore` matches `/e` and is thus directed to the `plugin_daemon` service, which does not handle these routes properly. To resolve this, you may need to adjust the Nginx configuration to ensure that requests to `/explore` are correctly routed to the `web` service instead of the `plugin_daemon`. You can modify the Nginx configuration file to add a specific location block for `/explore` that routes requests to the appropriate service. <!-- Dosu Comment Footer --> *To continue talking to [Dosu](https://dosu.dev), mention @dosu.* --- <sup>Help Dosu learn! Give it feedback: [Great Response](https://app.dosu.dev/response-feedback/68e84d93-88a9-43e4-b956-ef9a5b8ece90?feedback_type=great_response) | [Irrelevant Answer](https://app.dosu.dev/response-feedback/68e84d93-88a9-43e4-b956-ef9a5b8ece90?feedback_type=irrelevant_answer) | [Incorrect Sources](https://app.dosu.dev/response-feedback/68e84d93-88a9-43e4-b956-ef9a5b8ece90?feedback_type=incorrect_sources) | [Too Verbose](https://app.dosu.dev/response-feedback/68e84d93-88a9-43e4-b956-ef9a5b8ece90?feedback_type=too_verbose) | [Hallucination](https://app.dosu.dev/response-feedback/68e84d93-88a9-43e4-b956-ef9a5b8ece90?feedback_type=hallucination) | [Other](https://app.dosu.dev/response-feedback/68e84d93-88a9-43e4-b956-ef9a5b8ece90?feedback_type=other)</sup>
Author
Owner

@anoyi09 commented on GitHub (Feb 6, 2025):

find the file: dify/docker/nginx/conf.d/default.conf.template
config new content:

新增专门处理 /explore 路径的 location 块

location /explore {
  proxy_pass http://web:3000;  # 确保请求路由到 web 服务
  include proxy.conf;
}

location ^~ /e/ {
  proxy_pass http://plugin_daemon:5002;
  include proxy.conf;
}

Problem solving

@anoyi09 commented on GitHub (Feb 6, 2025): find the file: dify/docker/nginx/conf.d/default.conf.template config new content: # 新增专门处理 /explore 路径的 location 块 location /explore { proxy_pass http://web:3000; # 确保请求路由到 web 服务 include proxy.conf; } location ^~ /e/ { proxy_pass http://plugin_daemon:5002; include proxy.conf; } Problem solving
Author
Owner

@kurokobo commented on GitHub (Feb 9, 2025):

Closed via #12572

@kurokobo commented on GitHub (Feb 9, 2025): Closed via #12572
Sign in to join this conversation.
1 Participants
Notifications
Due Date
No due date set.
Dependencies

No dependencies set.

Reference: langgenius/dify#7630