import os os envirion DJANGO_SETTINGS_MODU LE settings from django cor

1
2
3
4
5
6
7
8
9
# 1
import os
os.envirion['DJANGO_SETTINGS_MODULE'] = 'settings'
# 2
from django.core.management import setup_environ
import settings
setup_environ(settings)