title: “settings.DATABASES is improperly configured” error performing syncdb with django 1.6.8
body: <p>I've setup devstack juno and django version 1.6.8. when want to run this command</p>
  
  <pre><code>python manage.py runserver
  </code></pre>
  
  <p>I got this following error:</p>
  
  <pre><code>WARNING:root:No local_settings file found.
  CommandError: You must set settings.ALLOWED_HOSTS if DEBUG is False.
  </code></pre>
  
  <p>I configured settings.py of django and this file looks like:</p>
  
  <pre><code>ALLOWED_HOSTS = ['*']
  
  
  # Application definition
  
  INSTALLED_APPS = (
      'django.contrib.admin',
      'django.contrib.auth',
      'django.contrib.contenttypes',
      'django.contrib.sessions',
      'django.contrib.messages',
      'django.contrib.staticfiles',
  )
  
  MIDDLEWARE_CLASSES = (
      'django.contrib.sessions.middleware.SessionMiddleware',
      'django.middleware.common.CommonMiddleware',
      'django.middleware.csrf.CsrfViewMiddleware',
      'django.contrib.auth.middleware.AuthenticationMiddleware',
      'django.contrib.messages.middleware.MessageMiddleware',
      'django.middleware.clickjacking.XFrameOptionsMiddleware',
  )
  
  ROOT_URLCONF = '{{ project_name }}.urls'
  
  WSGI_APPLICATION = '{{ project_name }}.wsgi.application'
  
  
  DATABASES = {
      'default': {
          'ENGINE': 'django.db.backends.mysql', 
          'NAME': '',
          'USER': 'root',
          'PASSWORD': '',
          'HOST': 'localhost',   # Or an IP Address that your DB is hosted on
          'PORT': '3306',
      }
  }
  
  
  # Internationalization
  # https://docs.djangoproject.com/en/{{ docs_version }}/topics/i18n/
  
  LANGUAGE_CODE = 'en-us'
  
  TIME_ZONE = 'UTC'
  
  USE_I18N = True
  
  USE_L10N = True
  
  USE_TZ = True
  
  
  # Static files (CSS, JavaScript, Images)
  # https://docs.djangoproject.com/en/{{ docs_version }}/howto/static-files/
  
  STATIC_URL = '/static/'
  
  try:
      from local_settings import *
  except ImportError:
      pass
  </code></pre>
  
  <p>And still this errors are found in eclipse when I want to run in eclipse </p>
  
  <p>Horizon --> Django--> Sync DB(manage.py syncdb)</p>
  
  <pre><code>WARNING:root:No local_settings file found.
  Traceback (most recent call last):
    File "/home/stack/git/horizon/manage.py", line 23, in &lt;module&gt;
      execute_from_command_line(sys.argv)
    File "/usr/local/lib/python2.7/dist-packages/django/core/management/__init__.py", line 399, in execute_from_command_line
      utility.execute()
    File "/usr/local/lib/python2.7/dist-packages/django/core/management/__init__.py", line 392, in execute
      self.fetch_command(subcommand).run_from_argv(self.argv)
    File "/usr/local/lib/python2.7/dist-packages/django/core/management/base.py", line 242, in run_from_argv
      self.execute(*args, **options.__dict__)
    File "/usr/local/lib/python2.7/dist-packages/django/core/management/base.py", line 285, in execute
      output = self.handle(*args, **options)
    File "/usr/local/lib/python2.7/dist-packages/django/core/management/base.py", line 415, in handle
      return self.handle_noargs(**options)
    File "/usr/local/lib/python2.7/dist-packages/django/core/management/commands/syncdb.py", line 57, in handle_noargs
      cursor = connection.cursor()
    File "/usr/local/lib/python2.7/dist-packages/django/db/backends/__init__.py", line 162, in cursor
      cursor = util.CursorWrapper(self._cursor(), self)
    File "/usr/local/lib/python2.7/dist-packages/django/db/backends/dummy/base.py", line 15, in complain
      raise ImproperlyConfigured("settings.DATABASES is improperly configured. "
  django.core.exceptions.ImproperlyConfigured: settings.DATABASES is improperly configured. Please supply the ENGINE value. Check settings documentation for more details.
  Finished "/home/stack/git/horizon/manage.py syncdb" execution.
  </code></pre>
  
  <p>Please help me to solve this error.</p>
  
  <p><strong>Edited:</strong></p>
  
  <p>Firstly I have DJANGO_SETTINGS_MODULE set problem.</p>
  
  <p>I have set DJANGO_SETTINGS_MODULE to openstack_dashboard.settings.</p>
  
  <p>and in horizon/openstack_dashboard folder I found settings.py and use database connection as answered below. Now it worked!!!</p>