Creating an app from a Template causes a 404 error [SELF_HOSTED]. #6931

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

Originally created by @oakhtar147 on GitHub (Nov 25, 2024).

Originally assigned to: @laipz8200 on GitHub.

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

0.12.0

Cloud or Self Hosted

Self Hosted (Docker)

Steps to reproduce

Went through the docs from here https://docs.dify.ai/getting-started/install-self-hosted/docker-compose

Did nothing by myself that could change the deployment.

I have not altered anything e.g. the .env file.

✔️ Expected Behavior

Creating an app from a template should work.

Actual Behavior

Creating an app from a template fails due a 404 error.

http://<server-ip>/console/api/apps/import not found (404).

Originally created by @oakhtar147 on GitHub (Nov 25, 2024). Originally assigned to: @laipz8200 on GitHub. ### 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 0.12.0 ### Cloud or Self Hosted Self Hosted (Docker) ### Steps to reproduce Went through the docs from here https://docs.dify.ai/getting-started/install-self-hosted/docker-compose Did nothing by myself that could change the deployment. I have not altered anything e.g. the `.env` file. ### ✔️ Expected Behavior Creating an app from a template should work. ### ❌ Actual Behavior Creating an app from a template fails due a 404 error. `http://<server-ip>/console/api/apps/import` not found (404).
yindo added the 🐞 bug label 2026-02-21 18:18:01 -05:00
yindo closed this issue 2026-02-21 18:18:01 -05:00
Author
Owner

@dosubot[bot] commented on GitHub (Nov 25, 2024):

Hey @oakhtar147! I'm here to help you with any bugs, questions, or contributions you have for the Dify app. Let's get to the bottom of this 404 error together.

I found a similar open issue regarding a "404 Not Found" error on a self-hosted Dify instance. The suggested solution involves several steps to ensure that all necessary services are running and properly configured. Here are the key steps you can follow:

  1. Ensure All Containers Are Running:
    Check that all required Docker containers are up and running using:

    docker compose ps
    

    Look for services like api, worker, web, weaviate, db, redis, and nginx.

  2. Check the Nginx Configuration:
    Verify that the Nginx container is correctly configured and running:

    docker compose ps | grep nginx
    
  3. Access the Correct URL:
    Make sure you are using the correct URL format. 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 for any errors:

    docker logs docker-nginx-1
    docker logs docker-web-1
    docker logs docker-api-1
    
  6. 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 when creating an app from a template [1].

To continue talking to Dosu, mention @dosu.

@dosubot[bot] commented on GitHub (Nov 25, 2024): <!-- Greeting --> Hey @oakhtar147! I'm here to help you with any bugs, questions, or contributions you have for the Dify app. Let's get to the bottom of this 404 error together. <!-- Answer --> I found a similar open issue regarding a "404 Not Found" error on a self-hosted Dify instance. The suggested solution involves several steps to ensure that all necessary services are running and properly configured. Here are the key steps you can follow: 1. **Ensure All Containers Are Running:** Check that all required Docker containers are up and running using: ```bash docker compose ps ``` Look for services like `api`, `worker`, `web`, `weaviate`, `db`, `redis`, and `nginx`. 2. **Check the Nginx Configuration:** Verify that the Nginx container is correctly configured and running: ```bash docker compose ps | grep nginx ``` 3. **Access the Correct URL:** Make sure you are using the correct URL format. For a local setup, it should be: ```plaintext http://localhost ``` 4. **Update and Restart Dify:** Update and restart your Dify instance: ```bash 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 for any errors: ```bash docker logs docker-nginx-1 docker logs docker-web-1 docker logs docker-api-1 ``` 6. **Verify Environment Variables:** Ensure all necessary environment variables are correctly set in your `docker-compose.yaml` file. For example: ```yaml 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 when creating an app from a template <sup>[[1]](https://github.com/langgenius/dify/issues/6129)</sup>. <!-- Dosu Comment Footer --> *To continue talking to [Dosu](https://dosu.dev), mention @dosu.*
Author
Owner

@poemDead commented on GitHub (Nov 25, 2024):

I got the same issue in the Cloud version too.
image

@poemDead commented on GitHub (Nov 25, 2024): I got the same issue in the Cloud version too. ![image](https://github.com/user-attachments/assets/ff61b73a-4450-4094-a285-a5941557d6ab)
Author
Owner

@minghe36 commented on GitHub (Nov 25, 2024):

I got the same issue in the Cloud version too.

@minghe36 commented on GitHub (Nov 25, 2024): I got the same issue in the Cloud version too.
Author
Owner

@oakhtar147 commented on GitHub (Nov 26, 2024):

wow thanks for the quick turnaround :D

@oakhtar147 commented on GitHub (Nov 26, 2024): wow thanks for the quick turnaround :D
Sign in to join this conversation.
1 Participants
Notifications
Due Date
No due date set.
Dependencies

No dependencies set.

Reference: langgenius/dify#6931