add celery scheduler and break app up into modules
This commit is contained in:
parent
d0a9851ae6
commit
9e1e3ad03f
19 changed files with 555 additions and 3 deletions
13
celeryconfig.py
Normal file
13
celeryconfig.py
Normal file
|
@ -0,0 +1,13 @@
|
|||
import datetime
|
||||
|
||||
BROKER_URL = 'redis://'
|
||||
CELERY_RESULT_BACKEND = 'redis'
|
||||
CELERY_TASK_SERIALIZER = 'json'
|
||||
CELERY_RESULT_SERIALIZER = 'json'
|
||||
CELERY_ACCEPT_CONTENT = ['json']
|
||||
CELERYBEAT_SCHEDULE = {
|
||||
'tick-every-5-minutes': {
|
||||
'task': 'tasks.tick',
|
||||
'schedule': datetime.timedelta(minutes=5),
|
||||
}
|
||||
}
|
Loading…
Add table
Add a link
Reference in a new issue