Source

ekkli-maps / settings.py

# Initialize App Engine and import the default settings (DB backend, etc.).
# If you want to use a different backend you have to remove all occurences
# of "djangoappengine" from this file.
from djangoappengine.settings_base import *

import os

# Activate django-dbindexer for the default database
DATABASES['native'] = DATABASES['default']
DATABASES['default'] = {'ENGINE': 'dbindexer', 'TARGET': 'native'}
AUTOLOAD_SITECONF = 'indexes'

SECRET_KEY = '=r-$b*8hglm+858&dns,dna,dmnas,dand,mnsa,d-&6-3d3vfc4((7yd0dbrakhvi'

CURRENT_SITE = 'ekkli-maps.appspot.com'
DEFAULT_FROM_EMAIL='voskoboynikvlad@googlemail.com'

INSTALLED_APPS = (
    'django.contrib.admin',
    'django.contrib.contenttypes',
    'invitation',
    'registration',
#    'googleappsauth',
    'django.contrib.auth',
    'django.contrib.sessions',
    'djangotoolbox',
    'autoload',
    'dbindexer',
    'permission_backend_nonrel',
    'common',
    'maps',
    'common',
    'releases',
    'upload',
    'filetransfers',
    'privatebeta',
    # djangoappengine should come last, so it can override a few manage.py commands
    'djangoappengine',
)

MIDDLEWARE_CLASSES = (
    # This loads the index definitions, so it has to come first
    'autoload.middleware.AutoloadMiddleware',
    'django.middleware.common.CommonMiddleware',
    'django.contrib.sessions.middleware.SessionMiddleware',
    'django.contrib.auth.middleware.AuthenticationMiddleware',
    'privatebeta.middleware.PrivateBetaMiddleware',
#    'googleappsauth.middleware.GoogleAuthMiddleware',
    'common.middleware.TokenMiddleWare',
    )

PRIVATEBETA_ENABLE_BETA=False
PRIVATEBETA_ALWAYS_ALLOW_VIEWS=['maps.views.dashboard','django.contrib.auth.views.login','common.services.connected','common.services.disconnected',]
PRIVATEBETA_REDIRECT_URL = '/invites'
PRIVATEBETA_ALWAYS_ALLOW_MODULES = ['django.contrib.admin.sites',]

TEMPLATE_CONTEXT_PROCESSORS = (
    'django.contrib.auth.context_processors.auth',
    'django.core.context_processors.request',
    'django.core.context_processors.media',
)

AUTHENTICATION_BACKENDS = (
     'permission_backend_nonrel.backends.NonrelPermissionBackend',
     'googleappsauth.backends.GoogleAuthBackend',
 )


# This test runner captures stdout and associates tracebacks with their
# corresponding output. Helps a lot with print-debugging.
TEST_RUNNER = 'djangotoolbox.test.CapturingTestSuiteRunner'

ADMIN_MEDIA_PREFIX = '/media/admin/'
TEMPLATE_DIRS = (os.path.join(os.path.dirname(__file__), 'templates'),)

ROOT_URLCONF = 'urls'

AUTH_PROFILE_MODULE='maps.UserProfile'

INVITE_MODE = True
ACCOUNT_INVITATION_DAYS = 30
ACCOUNT_ACTIVATION_DAYS = 20
INVITATIONS_PER_USER = 5


# marketplace configuration
LOGIN_REDIRECT_URL = '/'
#GOOGLE_APPS_DOMAIN ='cloudlockplus.com'  #'ekkli-maps.appspot.com'
GOOGLE_APPS_CONSUMER_KEY = '253718231002.apps.googleusercontent.com'
GOOGLE_APPS_CONSUMER_SECRET = 'O6ULPOvumXvZtYkHJ-V8S5LR'
# domain where your application is running
GOOGLE_OPENID_REALM = 'http://ekkli-maps.appspot.com/'
#GOOGLE_OPENID_ENDPOINT = 'https://www.google.com/a/%s/o8/ud?be=o8' % GOOGLE_APPS_DOMAIN
AUTH_PROTECTED_AREAS = ['/']