Hi, in crontab I put this:
DJANGO_SETTINGS_MODULE=mysite.settings 0 4 * * * python /path/to/maintenance/script.py The script is like this: #!/usr/bin/env(path to virtualenv folder) python some standard query.... Thanks, Alfredo 2011/11/10 nicolas HERSOG <n.her...@gmail.com>: > Can you show us your script and how you launch it ? > > On Wed, Nov 9, 2011 at 9:27 PM, Alfredo Alessandrini <alfreal...@gmail.com> > wrote: >> >> Hi, >> >> I'm running a script to make a query with django. >> >> I need to run it in crontab. >> >> When I run it I get this error: >> >> ImportError: No module named profiles >> >> I'm using a virtualenv. >> >> >> Thanks, >> >> Alfredo >> >> -- >> You received this message because you are subscribed to the Google Groups >> "Django users" group. >> To post to this group, send email to django-users@googlegroups.com. >> To unsubscribe from this group, send email to >> django-users+unsubscr...@googlegroups.com. >> For more options, visit this group at >> http://groups.google.com/group/django-users?hl=en. >> > > -- > You received this message because you are subscribed to the Google Groups > "Django users" group. > To post to this group, send email to django-users@googlegroups.com. > To unsubscribe from this group, send email to > django-users+unsubscr...@googlegroups.com. > For more options, visit this group at > http://groups.google.com/group/django-users?hl=en. > -- You received this message because you are subscribed to the Google Groups "Django users" group. To post to this group, send email to django-users@googlegroups.com. To unsubscribe from this group, send email to django-users+unsubscr...@googlegroups.com. For more options, visit this group at http://groups.google.com/group/django-users?hl=en.