Copy config from prod branch to main

This commit is contained in:
Mouse Reeve
2022-02-04 18:34:17 -08:00
parent 0601f68685
commit 7811a9920e
9 changed files with 70 additions and 25 deletions

13
celerywyrm/apps.py Normal file
View File

@ -0,0 +1,13 @@
from django.apps import AppConfig
from celerywyrm import settings
class CelerywyrmConfig(AppConfig):
name = "celerywyrm"
verbose_name = "BookWyrm Celery"
def ready(self):
if settings.OTEL_EXPORTER_OTLP_ENDPOINT:
from bookwyrm.telemetry import open_telemetry
open_telemetry.instrumentCelery()