Friday, March 26, 2021

Re: Have you experienced the thing I have done like the following.

Watching for file changes with StatReloader
Performing system checks...

System check identified no issues (0 silenced).
March 26, 2021 - 23:48:29
Django version 3.1.7, using settings 'django_app.settings'
Starting development server at http://127.0.0.1:8000/
Quit the server with CONTROL-C.

2021년 3월 26일 금요일 오후 11시 43분 19초 UTC+9에 Sangbom Suhk님이 작성:
Yes, I did. It's work fine.

2021년 3월 26일 금요일 오후 11시 37분 8초 UTC+9에 mr.xof...@gmail.com님이 작성:
Are you running your  manage.py runserver command in right directory

On Fri, 26 Mar 2021, 19:06 Sangbom Suhk, <enaga...@gmail.com> wrote:
Hi guyes!

Now I'm trying to install django framework and make python-based web. For this purpose, I installed apache2, python3.8.5 and libapache2-mod-wsgi-py3, and set a virtual host according to the django guide document.  My work flow was like the following. 

1. apt install apache2 apache2-dev libapache2-mod-wsgi-py3
2. apt install build-essential net-tools curl git software-properties-common python3
3. configured virtual host according to django guide document.
4. On my local account, I created virtualenv my domain under /var/www directory.
5. And I installed django, create django_app project like this "django-admin startproject django_app .".
6. And migrate my django project.
7. Next I browsed my site enagape.net, but I encountered the following errors. 

mod_wsgi (pid=5672): Failed to exec Python script file '/var/www/enagape.net_git/django_app/wsgi.py'.
mod_wsgi (pid=5672): Exception occurred processing WSGI script '/var/www/enagape.net_git/django_app/wsgi.py'.
Traceback (most recent call last):
  File "/var/www/enagape.net_git/django_app/wsgi.py", line 18, in <module>
    application = get_wsgi_application()
  File "/usr/lib/python3/dist-packages/django/core/wsgi.py", line 12, in get_wsgi_application
    django.setup(set_prefix=False)
  File "/usr/lib/python3/dist-packages/django/__init__.py", line 19, in setup
    configure_logging(settings.LOGGING_CONFIG, settings.LOGGING)
  File "/usr/lib/python3/dist-packages/django/conf/__init__.py", line 79, in __getattr__
    self._setup(name)
  File "/usr/lib/python3/dist-packages/django/conf/__init__.py", line 66, in _setup
    self._wrapped = Settings(settings_module)
  File "/usr/lib/python3/dist-packages/django/conf/__init__.py", line 157, in __init__
    mod = importlib.import_module(self.SETTINGS_MODULE)
  File "/usr/lib/python3.8/importlib/__init__.py", line 127, in import_module
    return _bootstrap._gcd_import(name[level:], package, level)
  File "<frozen importlib._bootstrap>", line 1014, in _gcd_import
  File "<frozen importlib._bootstrap>", line 991, in _find_and_load
  File "<frozen importlib._bootstrap>", line 961, in _find_and_load_unlocked
  File "<frozen importlib._bootstrap>", line 219, in _call_with_frames_removed
  File "<frozen importlib._bootstrap>", line 1014, in _gcd_import
  File "<frozen importlib._bootstrap>", line 991, in _find_and_load
  File "<frozen importlib._bootstrap>", line 973, in _find_and_load_unlocked
ModuleNotFoundError: No module named 'django_app'

Help me.

--
You received this message because you are subscribed to the Google Groups "Django users" group.
To unsubscribe from this group and stop receiving emails from it, send an email to django-users...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/django-users/de43f585-89e1-42c6-bc88-f518fa5d7fd1n%40googlegroups.com.

--
You received this message because you are subscribed to the Google Groups "Django users" group.
To unsubscribe from this group and stop receiving emails from it, send an email to django-users+unsubscribe@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/django-users/b99f9960-be50-46cb-bf4f-916b8d4b3364n%40googlegroups.com.

No comments:

Post a Comment