test celery

This commit is contained in:
Ross
2025-02-24 16:57:37 +00:00
parent c1f5147af7
commit f43c54f4af
8 changed files with 44 additions and 2 deletions
+3
View File
@@ -0,0 +1,3 @@
from .celery import app as celery_app
__all__ = ("celery_app",)
+7
View File
@@ -0,0 +1,7 @@
import os
from celery import Celery
os.environ.setdefault("DJANGO_SETTINGS_MODULE", "rad.settings")
app = Celery("rad")
app.config_from_object("django.conf:settings", namespace="CELERY")
app.autodiscover_tasks()
+6
View File
@@ -318,9 +318,15 @@ STATICFILES_DIRS = (
CIMAR_USERNAME = ""
CIMAR_PASSWORD = ""
# Celery settings
CELERY_BROKER_URL = "redis://redis:6379"
CELERY_RESULT_BACKEND = "redis://redis:6379"
try:
from .settings_local import *
except ImportError as e:
print(e)
print("UNABLE TO IMPORT LOCAL SETTINGS")
pass