Hi, Add following to a file(for e.g. cron_tasks.txt)
@daily RAILS_ENV=production /path/to/app/script/runner Controller(or Model or Mailer).method Add above file to crontab(cron table) by issuing following command, crontab cron_tasks.txt For specifics of crontab, look at following, http://www.adminschoice.com/docs/crontab.htm#Crontab%20file -Jatinder On 6/9/07, mike <[EMAIL PROTECTED]> wrote: > > > Hi, i've a little problem. i've to run a method every 5 minutes with > cron, but i don't know what and where i've to write it. The method is > written, but to run it ? i know that i've to use the script/runner (does > it take a lot of resources? does exist something better?), but to run it > every 5 minutes? > * 5 * * * script/runner -e production "Class.method" ? > and in which file should i put it ? (i'm under gentoo with vixie-cron) > Thanks > > -- > Posted via http://www.ruby-forum.com/. > > > > --~--~---------~--~----~------------~-------~--~----~ You received this message because you are subscribed to the Google Groups "Deploying Rails" group. To post to this group, send email to rubyonrails-deployment@googlegroups.com To unsubscribe from this group, send email to [EMAIL PROTECTED] For more options, visit this group at http://groups.google.com/group/rubyonrails-deployment?hl=en -~----------~----~----~----~------~----~------~--~---