GemPlugin::Plugin"/commands"
# File lib/mongrel_cluster/init.rb, line 284 def configure options [ ["-e", "--environment ENV", "Rails environment to run as", :@environment, nil], ['-p', '--port PORT', "Starting port to bind to", :@port, 3000], ['-a', '--address ADDR', "Address to bind to", :@address, nil], ['-l', '--log FILE', "Where to write log messages", :@log_file, "log/mongrel.log"], ['-P', '--pid FILE', "Where to write the PID", :@pid_file, "tmp/pids/mongrel.pid"], ['-c', '--chdir PATH', "Change to dir before starting (will be expanded)", :@cwd, nil], ['-o', '--timeout TIME', "Time to wait (in seconds) before killing a stalled thread", :@timeout, nil], ['-t', '--throttle TIME', "Time to pause (in hundredths of a second) between accepting clients", :@throttle, nil], ['-m', '--mime PATH', "A YAML file that lists additional MIME types", :@mime_map, nil], ['-r', '--root PATH', "Set the document root (default 'public')", :@docroot, nil], ['-n', '--num-procs INT', "Number of processor threads to use", :@num_procs, nil], ['-B', '--debug', "Enable debugging mode", :@debug, nil], ['-S', '--script PATH', "Load the given file as an extra config script.", :@config_script, nil], ['-N', '--num-servers INT', "Number of Mongrel servers", :@servers, 2], ['-C', '--config PATH', "Path to cluster configuration file", :@config_file, "config/mongrel_cluster.yml"], ['', '--user USER', "User to run as", :@user, nil], ['', '--group GROUP', "Group to run as", :@group, nil], ['', '--prefix PREFIX', "Rails prefix to use", :@prefix, nil] ] end
# File lib/mongrel_cluster/init.rb, line 316 def run @options = { "port" => @port, "servers" => @servers, "pid_file" => @pid_file } @options["log_file"] = @log_file if @log_file @options["debug"] = @debug if @debug @options["num_procs"] = @num_procs if @num_procs @options["docroot"] = @docroot if @docroot @options["address"] = @address if @address @options["timeout"] = @timeout if @timeout @options["throttle"] = @throttle if @throttle @options["environment"] = @environment if @environment @options["mime_map"] = @mime_map if @mime_map @options["config_script"] = @config_script if @config_script @options["cwd"] = @cwd if @cwd @options["user"] = @user if @user @options["group"] = @group if @group @options["prefix"] = @prefix if @prefix log "Writing configuration file to #{@config_file}." File.open(@config_file,"w") {|f| f.write(@options.to_yaml)} end
Generated with the Darkfish Rdoc Generator 2.