dify icon indicating copy to clipboard operation
dify copied to clipboard

The requested URL was not found on the server. If you entered the URL manually please check your spelling and try again.

Open duguwanglong opened this issue 1 year ago • 3 comments

Self Checks

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

Dify version

0.6.11

Cloud or Self Hosted

Self Hosted (Docker)

Steps to reproduce

I set the .env params as follow: image But when I commit the running, get the follow error: image image image

✔️ Expected Behavior

No response

❌ Actual Behavior

No response

duguwanglong avatar Jul 10 '24 03:07 duguwanglong

To resolve the "404 Not Found" error on your self-hosted Dify instance (version 0.6.11) running on Docker, follow these steps:

  1. Ensure All Containers Are Running: Verify that all necessary containers are up and running:

    docker compose ps
    

    You should see services like api, worker, web, weaviate, db, redis, and nginx running.

  2. Check the Nginx Configuration: Ensure the Nginx container is properly configured and running:

    docker compose ps | grep nginx
    
  3. Access the Correct URL: Make sure you are accessing the correct URL. For a local setup, it should be:

    http://localhost
    
  4. Update and Restart Dify: Update and restart your Dify instance:

    cd dify/docker
    git pull origin main
    docker compose down
    docker compose pull
    docker compose up -d
    
  5. Check Logs for Errors: Inspect the logs of the Nginx and other relevant containers:

    docker logs docker-nginx-1
    docker logs docker-web-1
    docker logs docker-api-1
    
  6. Verify Docker Compose Version: Ensure you are using the correct Docker Compose command based on your installed version:

    docker compose version
    
  7. Verify Environment Variables: Ensure all necessary environment variables are correctly set in your docker-compose.yaml file. For example:

    CONSOLE_WEB_URL: ${CONSOLE_WEB_URL}
    CONSOLE_API_URL: ${CONSOLE_API_URL}
    SERVICE_API_URL: ${SERVICE_API_URL}
    APP_WEB_URL: ${APP_WEB_URL}
    

By following these steps, you should be able to identify and resolve the "404 Not Found" error on your self-hosted Dify instance [1][2][3].

To continue talking to Dosu, mention @dosu.

dosubot[bot] avatar Jul 10 '24 03:07 dosubot[bot]

docker logs docker-web-1

All step is correct and normal 1 docker logs docker_web_1 image 2 docker logs docker_nginx_1 image 3 docker logs docker_api_1 image

duguwanglong avatar Jul 10 '24 03:07 duguwanglong

The frontend service is trying to access the url you defined. But it's not accessible. Please check the nginx configuration as well. You can test it by using curl command you copy from the chrome console.

From the above information I can not infer what is going on here.

You can inspect the failed request to see it's request url. And check it if this is the same with the CONSOLE_API_URL you set.

crazywoola avatar Jul 10 '24 04:07 crazywoola

image

how to fix?

krmao avatar Dec 17 '24 05:12 krmao