run_jruby_puma.py 476 B

12345678910111213141516
  1. import helper
  2. from helper import Command
  3. def start(args, logfile, errfile):
  4. db_host = "DB_HOST={0}".format(args.database_host or 'localhost')
  5. start_server = db_host + " rvm jruby-1.7.8 do bundle exec puma -C config/puma.rb"
  6. commands = [
  7. Command("rvm jruby-1.7.8 do bundle --jobs 4", True),
  8. Command(start_server, False)
  9. ]
  10. return helper.run(commands, logfile, errfile, args.troot)
  11. def stop(logfile, errfile):
  12. return helper.stop('puma', logfile, errfile)