Remove celery setting namespace.

Somehow it prevents celerybeat tasks from being registered.
Doesn't work with or without the namespace prefix on CELERYBEAT_SCHEDULE

Thanks @warlof
This commit is contained in:
Adarnof 2018-02-12 21:55:19 -05:00
parent a4003e188e
commit 631bb439a4
2 changed files with 2 additions and 2 deletions

View File

@ -10,7 +10,7 @@ app = Celery('{{ project_name }}')
# Using a string here means the worker don't have to serialize
# the configuration object to child processes.
app.config_from_object('django.conf:settings', namespace='CELERY')
app.config_from_object('django.conf:settings')
# Load task modules from all registered Django app configs.
app.autodiscover_tasks(lambda: settings.INSTALLED_APPS)

View File

@ -39,7 +39,7 @@ INSTALLED_APPS = [
]
# Celery configuration
CELERY_BROKER_URL = 'redis://localhost:6379/0'
BROKER_URL = 'redis://localhost:6379/0'
CELERYBEAT_SCHEDULER = "django_celery_beat.schedulers.DatabaseScheduler"
CELERYBEAT_SCHEDULE = {
'esi_cleanup_callbackredirect': {