add celery basics

This commit is contained in:
Laura Klünder 2016-09-27 15:32:42 +02:00
parent 78fc67ebdb
commit e8c1e7006c
4 changed files with 24 additions and 1 deletions

11
src/c3nav/celery.py Normal file
View file

@ -0,0 +1,11 @@
import os
from celery import Celery
os.environ.setdefault('DJANGO_SETTINGS_MODULE', 'c3nav.settings')
from django.conf import settings # noqa
app = Celery('c3nav')
app.config_from_object('django.conf:settings')
app.autodiscover_tasks(lambda: settings.INSTALLED_APPS)