[GeoNode-users] No module named 'geonode.local_settings'

Jose Cáceres jose.atyus at gmail.com
Mon Jan 18 08:40:57 PST 2021


Hi,

I'm trying to use a local_settings.py file to deploy Geonode 3.1 using
Docker.

I created a local_settings.py file inside /opt/geonode/geonode, and I added
the variable *DJANGO_SETTINGS_MODULE=geonode.local_settings* to the docker-
*compose.override.localhost.yml* file, but it exit with error code 1 while
making migrations. The *invoke.log* show this:

*Traceback (most recent call last):*
*  File "manage.py", line 29, in <module>*
*    execute_from_command_line(sys.argv)*
*  File
"/usr/local/lib/python3.8/site-packages/django/core/management/__init__.py",
line 381, in execute_from_command_line*
*    utility.execute()*
*  File
"/usr/local/lib/python3.8/site-packages/django/core/management/__init__.py",
line 375, in execute*
*    self.fetch_command(subcommand).run_from_argv(self.argv)*
*  File
"/usr/local/lib/python3.8/site-packages/django/core/management/base.py",
line 336, in run_from_argv*
*    connections.close_all()*
*  File "/usr/local/lib/python3.8/site-packages/django/db/utils.py", line
219, in close_all*
*    for alias in self:*
*  File "/usr/local/lib/python3.8/site-packages/django/db/utils.py", line
213, in __iter__*
*    return iter(self.databases)*
*  File
"/usr/local/lib/python3.8/site-packages/django/utils/functional.py", line
80, in __get__*
*    res = instance.__dict__[self.name <http://self.name>] =
self.func(instance)*
*  File "/usr/local/lib/python3.8/site-packages/django/db/utils.py", line
147, in databases*
*    self._databases = settings.DATABASES*
*  File "/usr/local/lib/python3.8/site-packages/django/conf/__init__.py",
line 79, in __getattr__*
*    self._setup(name)*
*  File "/usr/local/lib/python3.8/site-packages/django/conf/__init__.py",
line 66, in _setup*
*    self._wrapped = Settings(settings_module)*
*  File "/usr/local/lib/python3.8/site-packages/django/conf/__init__.py",
line 157, in __init__*
*    mod = importlib.import_module(self.SETTINGS_MODULE)*
*  File "/usr/local/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 973, in
_find_and_load_unlocked*
*ModuleNotFoundError: No module named 'geonode.local_settings'*


I can get it to work using the default settings.py. I found this ticket
https://github.com/GeoNode/geonode/issues/6618 advising to change
'.:/usr/src/app' for '.:/usr/src/geonode' but I got the exact same result.

Hope someone can point me in the right direction.

Kind regards,

-- 
José David Cáceres
Ingeniero Ambiental
Máster en Tecnologías de la Información Geográfica
e-mail: jose.atyus at gmail.com


[image: Mailtrack]
<https://mailtrack.io?utm_source=gmail&utm_medium=signature&utm_campaign=signaturevirality5&>
Remitente
notificado con
Mailtrack
<https://mailtrack.io?utm_source=gmail&utm_medium=signature&utm_campaign=signaturevirality5&>
18/01/21
10:40:23
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.osgeo.org/pipermail/geonode-users/attachments/20210118/a02049bf/attachment.html>


More information about the geonode-users mailing list