frappe / frappe_docker

Docker images for production and development setups of the Frappe framework and ERPNext
MIT License
1.41k stars 1.32k forks source link

Internal Server Error straight after fresh install #1361

Closed KansaiGaijin closed 2 months ago

KansaiGaijin commented 6 months ago

Description of the issue

Fresh install following GitHub instructions here https://github.com/frappe/frappe_docker and following this video https://www.youtube.com/watch?v=IP8NpcvcIDk

Context information (for bug reports)

Followed instructions for creating the containers from clone of the github contents, waited for logs to clear and show everything is complete, access website at local.ip:port and am met with Internal Server Error.

Steps to reproduce the issue

jamie@KansaiGaijin:~/Docker/ERPNext/frappe_docker$ nano pwd.yml
jamie@KansaiGaijin:~/Docker/ERPNext/frappe_docker$ docker compose -f pwd.yml up -d
[+] Running 36/21
 ✔ configurator Pulled                                                   167.7s
 ✔ db 8 layers [⣿⣿⣿⣿⣿⣿⣿⣿]      0B/0B      Pulled                          94.8s
 ✔ backend Pulled                                                        167.2s
 ✔ queue-short Pulled                                                    167.0s
 ✔ create-site Pulled                                                    167.4s
 ✔ queue-long Pulled                                                     167.5s
 ✔ redis-queue Pulled                                                     71.0s
 ✔ frontend Pulled                                                       166.8s
 ✔ scheduler Pulled                                                      167.3s
 ✔ websocket 10 layers [⣿⣿⣿⣿⣿⣿⣿⣿⣿⣿]      0B/0B      Pulled               166.9s
 ✔ redis-cache 7 layers [⣿⣿⣿⣿⣿⣿⣿]      0B/0B      Pulled                  71.1s
[+] Running 17/17
 ✔ Network frappe_docker_default            Created                        2.3s
 ✔ Volume "frappe_docker_logs"              Created                        0.7s
 ✔ Volume "frappe_docker_redis-cache-data"  Created                        0.1s
 ✔ Volume "frappe_docker_db-data"           Created                        0.1s
 ✔ Volume "frappe_docker_redis-queue-data"  Created                        0.1s
 ✔ Volume "frappe_docker_sites"             Created                        0.1s
 ✔ Container frappe_docker-db-1             Created                       16.2s
 ✔ Container frappe_docker-redis-queue-1    Created                       17.0s
 ✔ Container frappe_docker-redis-cache-1    Created                       17.1s
 ✔ Container frappe_docker-backend-1        Created                       17.0s
 ✔ Container frappe_docker-queue-long-1     Created                       17.0s
 ✔ Container frappe_docker-websocket-1      Created                       17.0s
 ✔ Container frappe_docker-queue-short-1    Created                       17.0s
 ✔ Container frappe_docker-scheduler-1      Created                       17.0s
 ✔ Container frappe_docker-configurator-1   Created                       17.0s
 ✔ Container frappe_docker-create-site-1    Created                       17.0s
 ✔ Container frappe_docker-frontend-1       Created                        3.1s
Attaching to backend-1, configurator-1, create-site-1, db-1, frontend-1, queue-l                                                                                                                                                             ong-1, queue-short-1, redis-cache-1, redis-queue-1, scheduler-1, websocket-1

jamie@KansaiGaijin:~/Docker/ERPNext/frappe_docker$ docker logs frappe_docker-create-site-1 -f
wait-for-it: waiting 120 seconds for db:3306
wait-for-it: db:3306 is available after 101 seconds
wait-for-it: waiting 120 seconds for redis-cache:6379
wait-for-it: redis-cache:6379 is available after 0 seconds
wait-for-it: waiting 120 seconds for redis-queue:6379
wait-for-it: redis-queue:6379 is available after 0 seconds
sites/common_site_config.json found

Installing frappe...
Updating D
Updating DocTypes for frappe        : [========================================] 100%
Updating Dashboard for frappe

Installing erpnext...
Updating DocTypes for erpnext       : [========================================] 100%
Updating customizations for Address
Updating customizations for Contact
Updating Dashboard for erpnext
*** Scheduler is disabled ***
Current Site set to frontend
jamie@KansaiGaijin:~/Docker/ERPNext/frappe_docker$

Observed result

Navigate to 192.168.0.240:3636 and am met with Internal Server Error message in bold on white background.

Expected result

ERPNext frontend loads to login

KansaiGaijin commented 6 months ago

I can confirm apps.txt has

erpnext
frappe

The backend container logs show this

File "/home/frappe/frappe-bench/apps/frappe/frappe/__init__.py", line 1286, in get_doc
    doc = frappe.model.document.get_doc(*args, **kwargs)
          ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/home/frappe/frappe-bench/apps/frappe/frappe/model/document.py", line 83, in get_doc
    controller = get_controller(doctype)
                 ^^^^^^^^^^^^^^^^^^^^^^^
  File "/home/frappe/frappe-bench/apps/frappe/frappe/model/base_document.py", line 70, in get_controller
    site_controllers[doctype] = import_controller(doctype)
                                ^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/home/frappe/frappe-bench/apps/frappe/frappe/model/base_document.py", line 95, in import_controller
    module = load_doctype_module(doctype, module_name)
             ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/home/frappe/frappe-bench/apps/frappe/frappe/modules/utils.py", line 231, in load_doctype_module
    app = get_module_app(module)
          ^^^^^^^^^^^^^^^^^^^^^^
  File "/home/frappe/frappe-bench/apps/frappe/frappe/modules/utils.py", line 256, in get_module_app
    frappe.throw(_("Module {} not found").format(module), exc=frappe.DoesNotExistError)
  File "/home/frappe/frappe-bench/apps/frappe/frappe/__init__.py", line 602, in throw
    msgprint(
  File "/home/frappe/frappe-bench/apps/frappe/frappe/__init__.py", line 567, in msgprint
    _raise_exception()
  File "/home/frappe/frappe-bench/apps/frappe/frappe/__init__.py", line 518, in _raise_exception
    raise exc
frappe.exceptions.DoesNotExistError: Module Website not found
KansaiGaijin commented 6 months ago

Any chance for a response?

revant commented 5 months ago

Try reinstalling the site? Somehow I am not able to recreate this.

JamilIrshad commented 4 months ago

@revant I am having the same issue. First when I installed it on windows using Docker Desktop, it produced "Internal Server Error" and then when I tried using the Docker PWD button in readme, it is giving me the same error. I have tried it on an EC2 Amazon Linux using docker compose and it works there without issue but it is slow.

github-actions[bot] commented 2 months ago

This issue has been automatically marked as stale. You have a week to explain why you believe this is an error.

AkkoSpace commented 1 month ago

The same issue, can anyone help?

DevJulian1966 commented 1 month ago

+1 Having a very similar issue after restarting the host.

MrDay2Day commented 1 month ago

Same issue here...

indrawow commented 3 weeks ago

+1. Before run smooth, next day run bench start got this error.

ipaqmaster commented 3 weeks ago

Same here. Brand new and the docker containers start together but I'm immediately greeted with an Internal Server Error page.

Just the other week it showed the initial login screen.

EasternIndustries-IT commented 3 weeks ago

Same Issues on ubuntu 22.04 but works on windows 11.