Sha256: d2138d02f4be4531abf39a80c05c0be66242f630fb922f9c0fae5b3b42570c1f
Contents?: true
Size: 687 Bytes
Versions: 17
Compression:
Stored size: 687 Bytes
Contents
#!/usr/bin/env ruby # # Zena Startup script # # chkconfig: - 85 15 # description: zena manages Zena # apps = Dir['/var/*/app/current'] cmd = ARGV.first operations = [ 'ruby lib/upload_progress_server.rb ', 'rake worker:', 'mongrel_rails cluster::', ] if %w{stop restart}.include?(cmd) apps.each do |app| puts "Stopping #{app}..." operations.each do |op| `cd #{app} && #{op}stop` end end end if %w{start restart}.include?(cmd) apps.each do |app| puts "Starting #{app}..." operations.each do |op| `cd #{app} && #{op}start` end end end unless %w{start stop restart}.include?(cmd) puts "Usage: zena {start|stop|restart}" exit end
Version data entries
17 entries across 17 versions & 1 rubygems