Problem with autostart of Redmine on CentOS 6.5
Added by Alex N almost 11 years ago
Please help me to make Redmine autostart.
Firstly i added an string to rc.local - it looks like this:
/usr/local/rvm/rubies/ruby-2.0.0-p451/bin/ruby /var/www/redmine/script/rails server -p 3000 -e production
but with no luck
then i created an "autoloading enabled" file "startredmine" in folder init.d and this method failed too
contents of "startredmine"------------------------------------
#!/bin/bash #
- BEGIN INIT INFO
- Provides: blk-availability
- Required-Start:
- Required-Stop:
- Default-Start: 1 2 3 4 5
- Default-Stop: 0 6
- Short-Description: Availability of block devices
- END INIT INFO
. /etc/init.d/functions
rtrn=1
case "$1" in
start)
/usr/local/rvm/rubies/ruby-2.0.0-p451/bin/ruby /var/www/redmine/script/rails server -p 3000 -e production
;;
stop)
;;
status)
;;
*)
echo $"Usage: $0 {start|stop|status}"
;;
esac
---------------------------------------------------------------
--------------------------------------------------------------------------
[root@vps redmine]# RAILS_ENV=production script/about
sh: darcs: command not found
sh: hg: command not found
sh: bzr: command not found
Environment:
Redmine version 2.5.1.stable.13103
Ruby version 2.0.0-p451 (2014-02-24) [x86_64-linux]
Rails version 3.2.17
Environment production
Database adapter Mysql2
SCM:
Subversion 1.6.11
Git 1.7.1
Filesystem
Redmine plugins:
no plugin installed