Use rvm in cron

  1. rvm list
    1. find what looks like your gems set, e.g
        1. ruby-1.9.3-p194
  2. echo $rvm_path/bin, e.g.
    1. /usr/lib/rvm/bin
  3. tack on the output of #1 to the output of #2, e.g.
    1. /usr/lib/rvm/bin/ruby-1.9.3-p194
  4. your cron entry should be the result of #3 followed by your ruby script, e.g.
    1. 0 0 * * * /usr/lib/rvm/bin/ruby-1.9.3-p194 /optt/mydir/myscript.rb


Popular posts from this blog

Debugging pfsense firewall rules clearly and easily

Direct ssh to a server via proxy using putty/plink on Windows

telnet vs netcat