Ask Your Question
0

What permissions/environment setting are needed to run the send_email_alerts?

asked 2011-02-23 17:49:18 -0500

tfoote gravatar image

updated 2011-03-01 13:08:46 -0500

Evgeny gravatar image

The documentation is kind of light on this and I ran into problems with "environment variable DJANGO_SETTINGS_MODULE is undefined"

http://askbot.org/doc/management-commands.html

edit retag flag offensive close merge delete

1 Answer

Sort by ยป oldest newest most voted
0

answered 2011-02-23 18:17:27 -0500

Evgeny gravatar image

The reason you get that error is that the settings.py file is not on on the python path when the script is executed.

There is a sample job file askbot/cron/askbot_cron_job, where PYTHONPATH is modified.

I've relabeled your post as "bug" because the deployment command must ideally configure those jobs automatically.

edit flag offensive delete link more

Comments

Thanks I ended up using the following: """PROJECT_PARENT_DIR=/var/www export PYTHONPATH=$PROJECT_PARENT_DIR:$PYTHONPATH #these are actual commands that are to be run python $PROJECT_PARENT_DIR/manage.py send_email_alerts """
tfoote gravatar imagetfoote ( 2011-02-24 16:37:28 -0500 )edit
good. the reason the comment formatting is off is that the two $ signs initiate mathjax rendering. I think if you back-slash escape them the problem should go away. Otherwise, there is no easy fix at this time.
Evgeny gravatar imageEvgeny ( 2011-02-24 16:42:26 -0500 )edit

Your Answer

Please start posting anonymously - your entry will be published after you log in or create a new account.

Add Answer

Question Tools

Stats

Asked: 2011-02-23 17:49:18 -0500

Seen: 132 times

Last updated: Feb 23 '11