"Django celery beat" table is not filled

0

I started in a Django project that already had Django Celery Beat and some records of some Task's in their tables:

  • django_celery_beat_crontabschedule
  • django_celery_beat_intervalschedule
  • django_celery_beat_periodictask
  • django_celery_beat_periodictasks

I'm new to Celery and recently I created a Task:

  # Task
  @shared_task(priority=1)
  def exemplo_task():
    # ...

And I logged into Settings.py:

  # Settings
   DJANGO_APPS = (
    # Outros apps...
    'django_celery_beat',
    # Outros apps...
    )

   CELERYBEAT_SCHEDULER = {
    # ...
       'exemplo-task': {
        'task': 'exemplo.tasks.exemplo_task',
        'schedule': crontab(minute=0, hour=0),
        'queue': 'beat'
    }
   # ...     
   }

Follow my Pip:

# Pip list
# ...
celery                           4.1.1
django-celery-beat               1.0.1
# ...

My doubt is, I have no idea how I can register in my celery beat tables my task, rodei migrate, I researched and did not find anything that worked, how I can register it in my database so I can access the Tasks on my Django Admin page? Or would I have to manually register in the admin, even though I already configured the task in the code? That would be my question.

    
asked by anonymous 10.07.2018 / 14:58

0 answers