【问题标题】:crontab config issuescrontab 配置问题
【发布时间】:2010-08-10 02:10:53
【问题描述】:

我想为我的 thinking_sphinx 搜索功能设置一个 crontab。我没有为此使用任何红宝石。

这是我的命令

*/59 * * * * cd path && rake thinking_sphinx:index RAILS_ENV=production

系统日志给了我这个:

CRON[2890]: (user) CMD (cd path && rake thinking_sphinx:index RAILS_ENV=production)

然而thinking_sphinx 没有被索引。如果我手动索引它,它确实有效。

【问题讨论】:

    标签: ruby-on-rails crontab


    【解决方案1】:

    我在 crontab 文件的顶部添加了这些,现在它可以工作了。

    PATH=/usr/local/bin:/usr/bin:/bin

    SHELL=/bin/bash

    【讨论】:

      猜你喜欢
      • 2012-07-18
      • 2018-08-28
      • 1970-01-01
      • 2013-01-26
      • 2019-06-17
      • 2022-01-05
      • 1970-01-01
      • 1970-01-01
      • 1970-01-01
      相关资源
      最近更新 更多