Calling django methods from a twisted server -
consider problem, in parent directory there 2 (2) directories. in 1 directory root django server whilst directory root twisted server. twisted server receives data, whilst django server serves data website , manages database.
|-root- django -| |-manage.py |-site/ - twisted -| |-server.py
i want twisted server able supply data models in django site, however, getting following error when calling methods.
you must either define environment variable django_settings_module or call settings.configure() before accessing settings.
which best workaround this?
to exactly tells to.
export django_settings_module=yoursite.settings
...
setup_environ(settings)
...
settings.configure(...)
Comments
Post a Comment