define celery settings

This commit is contained in:
2017-02-11 19:23:59 +01:00
parent e84b2f54a9
commit 9a18080db9
2 changed files with 4 additions and 1 deletions

View File

@@ -2,11 +2,12 @@ from __future__ import absolute_import, unicode_literals
import os
import django
from celery import Celery
from django.conf import settings
# set the default Django settings module for the 'celery' program.
os.environ.setdefault('DJANGO_SETTINGS_MODULE', 'caromserver.settings')
app = Celery('caromserver')
app = Celery(settings.CELERY_PREFIX)
# Using a string here means the worker don't have to serialize
# the configuration object to child processes.