我正在尝试在服务器中设置一个 cron 作业,我在 cron 选项卡中写了这一行:
DJANGO_SETTINGS_MODULE=settings_local PYTHONPATH=$HOME/django-locate:$HOME/locate/locate python manage.py testcommand
但我收到var/mail/myname
错误消息,说找不到 manage.py。
我在这里做错了什么?
这是我的 cronjob:
class Command(BaseCommand):
args = "<test cron job>"
help = "writes locations from other server"
def handle(self,*args,**options):
self.stdout.write("cron job is running - it is just a test ")