Hi,
Thanks for the advice.
I actually found that just after writing my post. Now the cron job works
perfectly.
Thanks,
On 10/14/2015 3:26 PM, Vijay Khemlani wrote:
The easiest way would be using a custom management command
https://docs.djangoproject.com/en/1.8/howto/custom-management-commands/
On Wed, Oct 14, 2015 at 10:53 AM, 'Chris Norman' via Django users
<django-users@googlegroups.com <mailto:django-users@googlegroups.com>>
wrote:
Hi again,
I would like to set up a cron job to email the day's journeys to a
pre-defined set of email addresses, using the model I described in
the previous example.
I have it so I can type:
python manage.py shell
import journey_sender
This does everything.
Thing is, I would like to use the server's cron demon to do this,
so I can't work it in the way I just described. I tried using
combinations of pipe characters, but to no avail.
Is there some way I can programatically simulate the shell yielded
by manage.py? Or is there a smarter way of running the cron job
from within Django it's self?
Thanks in advance,
--
You received this message because you are subscribed to the Google
Groups "Django users" group.
To unsubscribe from this group and stop receiving emails from it,
send an email to django-users+unsubscr...@googlegroups.com
<mailto:django-users%2bunsubscr...@googlegroups.com>.
To post to this group, send email to django-users@googlegroups.com
<mailto:django-users@googlegroups.com>.
Visit this group at http://groups.google.com/group/django-users.
To view this discussion on the web visit
https://groups.google.com/d/msgid/django-users/561E5E70.3060901%40googlemail.com.
For more options, visit https://groups.google.com/d/optout.
--
You received this message because you are subscribed to the Google
Groups "Django users" group.
To unsubscribe from this group and stop receiving emails from it, send
an email to django-users+unsubscr...@googlegroups.com
<mailto:django-users+unsubscr...@googlegroups.com>.
To post to this group, send email to django-users@googlegroups.com
<mailto:django-users@googlegroups.com>.
Visit this group at http://groups.google.com/group/django-users.
To view this discussion on the web visit
https://groups.google.com/d/msgid/django-users/CALn3ei1wGy6WdBeOoM7KULuLQ45wtDXEsVX0NRExfruuTe8W8g%40mail.gmail.com
<https://groups.google.com/d/msgid/django-users/CALn3ei1wGy6WdBeOoM7KULuLQ45wtDXEsVX0NRExfruuTe8W8g%40mail.gmail.com?utm_medium=email&utm_source=footer>.
For more options, visit https://groups.google.com/d/optout.
--
You received this message because you are subscribed to the Google Groups "Django
users" group.
To unsubscribe from this group and stop receiving emails from it, send an email
to django-users+unsubscr...@googlegroups.com.
To post to this group, send email to django-users@googlegroups.com.
Visit this group at http://groups.google.com/group/django-users.
To view this discussion on the web visit
https://groups.google.com/d/msgid/django-users/561E7877.8080706%40googlemail.com.
For more options, visit https://groups.google.com/d/optout.