Fixes #517. Moves to gcloud
This commit is contained in:
Родитель
c85ab2d772
Коммит
a33a626259
|
@ -18,4 +18,5 @@ bulkloader-*
|
|||
css/
|
||||
static/dist/
|
||||
cookie
|
||||
lib
|
||||
lib
|
||||
env_vars.yaml
|
||||
|
|
4
app.yaml
4
app.yaml
|
@ -5,9 +5,6 @@ instance_class: F2
|
|||
|
||||
# default_expiration: "30s"
|
||||
|
||||
env_variables:
|
||||
DJANGO_SETTINGS_MODULE: 'settings'
|
||||
|
||||
builtins:
|
||||
- remote_api: on
|
||||
|
||||
|
@ -116,3 +113,4 @@ handlers:
|
|||
|
||||
includes:
|
||||
- skip_files.yaml
|
||||
- env_vars.yaml
|
|
@ -325,7 +325,7 @@ class Feature(DictModel):
|
|||
|
||||
@classmethod
|
||||
def get_feature_chunk_memcache_keys(self, key_prefix):
|
||||
num_features = Feature.all(keys_only=True).count()
|
||||
num_features = len(Feature.all().fetch(limit=None, keys_only=True))
|
||||
l = list_to_chunks(range(0, num_features), self.MAX_CHUNK_SIZE)
|
||||
return ['%s|chunk%s' % (key_prefix, i) for i,val in enumerate(l)]
|
||||
|
||||
|
|
|
@ -1,7 +1,7 @@
|
|||
runtime: python27
|
||||
api_version: 1
|
||||
threadsafe: true
|
||||
module: notifier
|
||||
service: notifier
|
||||
|
||||
handlers:
|
||||
- url: /.*
|
||||
|
@ -10,3 +10,4 @@ handlers:
|
|||
|
||||
includes:
|
||||
- skip_files.yaml
|
||||
- env_vars.yaml
|
||||
|
|
|
@ -27,7 +27,8 @@ readonly FIREBASE_SERVER_KEY=`cat .fcm_server_key`
|
|||
gulp
|
||||
|
||||
$BASEDIR/oauthtoken.sh deploy
|
||||
appcfg.py update -A cr-status \
|
||||
-V $deployVersion \
|
||||
--env_variable=FIREBASE_SERVER_KEY:$FIREBASE_SERVER_KEY \
|
||||
gcloud app deploy \
|
||||
--project cr-status \
|
||||
--version $deployVersion \
|
||||
--no-promote \
|
||||
$BASEDIR/../app.yaml $BASEDIR/../notifier.yaml
|
||||
|
|
|
@ -9,5 +9,4 @@ readonly BASEDIR=$(dirname $BASH_SOURCE)
|
|||
readonly FIREBASE_SERVER_KEY=`cat .fcm_server_key`
|
||||
|
||||
dev_appserver.py -A cr-status \
|
||||
--env_var FIREBASE_SERVER_KEY=$FIREBASE_SERVER_KEY \
|
||||
$BASEDIR/../app.yaml $BASEDIR/../notifier.yaml
|
||||
|
|
Загрузка…
Ссылка в новой задаче