pip install django-crontab
INSTALLED_APPS = [
.
.
'django_crontab',
.
.
]
def crontab_hello():
print('hello')
CRONJOBS = [
('* * * * *', 'study_group.cron.crontab_penalty_student', '>> '+os.path.join(BASE_DIR, 'stady/log/cron.log')),
]
python manage.py crontab show
python manage.py crontab add
python manage.py crontab remove