範本: appengine_config.py
appengine_config.py
import site
import os
CUR_PATH = os.path.dirname(os.path.abspath(__file__))
SITE_PATH = os.path.join(CUR_PATH, 'site-packages/')
site.addsitedir(SITE_PATH)
SITE_PATH = os.path.join(CUR_PATH, 'backend/')
site.addsitedir(SITE_PATH)
SITE_PATH = os.path.join(CUR_PATH, 'share_libs/')
site.addsitedir(SITE_PATH)
os.environ['GOOGLE_SQL_OAUTH2_REFRESH_TOKEN'] = "1/oBl4zHM5miWHllLsKkGzXp7mFVvkFo9ZBae9gKAZBaw"
-------------------------------------------------------------------
app.yaml
application: xxxxxxx
version: xxxxx
runtime: python27
api_version: 1
threadsafe: true
libraries:
- name: ssl
version: latest
- name: django
version: 1.5
- name: PIL
version: latest
- name: lxml
version: latest
- name: pycrypto
version: latest
includes:
- trackers/track.yaml
- mapreduce/include.yaml
handlers:
- url: /api_server/static
static_dir: ad_api/static/api_server
- url: /static/new_xxx
static_dir: backend/new_xxx/static/new_xxx
- url: /static/xxx
static_dir: backend/xxx/static/xxx
- url: /static
static_dir: static
- url: /sandbox/.*
script: sandbox.app
#- url: /backend/api/.*
# script: front_fake.index.app
#- url: /api_server/api/.*
# script: front_fake.index.app
- url: /api_server/.*
script: ad_api.index.app
- url: /.*
script: backend.conf.wsgi.application
skip_files:
- ^site-packages/.*\.egg-info(/.*)?
- ^site-packages/app.pth$
- ^build$
- ^pip$
- .*.scssc$
- .*.pyc$
- .*.scss$
- .*.php$
- .*.md$
- ^easy_install$
- ^.*/local_settings.pyc?$
env_variables:
DJANGO_SETTINGS_MODULE: 'backend.conf.settings'
import site
import os
CUR_PATH = os.path.dirname(os.path.abspath(__file__))
SITE_PATH = os.path.join(CUR_PATH, 'site-packages/')
site.addsitedir(SITE_PATH)
SITE_PATH = os.path.join(CUR_PATH, 'backend/')
site.addsitedir(SITE_PATH)
SITE_PATH = os.path.join(CUR_PATH, 'share_libs/')
site.addsitedir(SITE_PATH)
os.environ['GOOGLE_SQL_OAUTH2_REFRESH_TOKEN'] = "1/oBl4zHM5miWHllLsKkGzXp7mFVvkFo9ZBae9gKAZBaw"
-------------------------------------------------------------------
app.yaml
application: xxxxxxx
version: xxxxx
runtime: python27
api_version: 1
threadsafe: true
libraries:
- name: ssl
version: latest
- name: django
version: 1.5
- name: PIL
version: latest
- name: lxml
version: latest
- name: pycrypto
version: latest
includes:
- trackers/track.yaml
- mapreduce/include.yaml
handlers:
- url: /api_server/static
static_dir: ad_api/static/api_server
- url: /static/new_xxx
static_dir: backend/new_xxx/static/new_xxx
- url: /static/xxx
static_dir: backend/xxx/static/xxx
- url: /static
static_dir: static
- url: /sandbox/.*
script: sandbox.app
#- url: /backend/api/.*
# script: front_fake.index.app
#- url: /api_server/api/.*
# script: front_fake.index.app
- url: /api_server/.*
script: ad_api.index.app
- url: /.*
script: backend.conf.wsgi.application
skip_files:
- ^site-packages/.*\.egg-info(/.*)?
- ^site-packages/app.pth$
- ^build$
- ^pip$
- .*.scssc$
- .*.pyc$
- .*.scss$
- .*.php$
- .*.md$
- ^easy_install$
- ^.*/local_settings.pyc?$
env_variables:
DJANGO_SETTINGS_MODULE: 'backend.conf.settings'
留言
張貼留言