forked from devsar/django-gae-backends
-
Notifications
You must be signed in to change notification settings - Fork 0
/
README
38 lines (32 loc) · 938 Bytes
/
README
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
A collection a django backends for the Google App Engine
Features:
- memcache/datastore session backend
- email backend
- cache backend
- rdbms for migrations
TODO:
- file storage base in the Google Cloud Storage
Setup
=====
Add to the settings.py the following lines to install the backends:
SESSION_ENGINE = "gae_backends.sessions.cached_db"
EMAIL_BACKEND = "gae_backends.mail.EmailBackend"
CACHES = {
'default': {
'BACKEND': 'gae_backends.memcache.MemcacheCache',
}
}
if os.getenv('SETTINGS_MODE') == 'prod':
# Running in development, but want to access the Google Cloud SQL instance
# in production.
DATABASES = {
'default': {
'ENGINE': 'gae_backends.rdbms',
'INSTANCE': 'your_instance:your_db',
'NAME': '....',
'USER': '....',
'OPTIONS': {
'init_command': 'SET storage_engine=INNODB',
}
}
}