Module: Bluepill

Defined in:
lib/bluepill/dsl.rb,
lib/bluepill/group.rb,
lib/bluepill/logger.rb,
lib/bluepill/socket.rb,
lib/bluepill/system.rb,
lib/bluepill/process.rb,
lib/bluepill/trigger.rb,
lib/bluepill/version.rb,
lib/bluepill/controller.rb,
lib/bluepill/application.rb,
lib/bluepill/dsl/app_proxy.rb,
lib/bluepill/condition_watch.rb,
lib/bluepill/process_journal.rb,
lib/bluepill/dsl/process_proxy.rb,
lib/bluepill/triggers/flapping.rb,
lib/bluepill/application/client.rb,
lib/bluepill/application/server.rb,
lib/bluepill/process_conditions.rb,
lib/bluepill/process_statistics.rb,
lib/bluepill/dsl/process_factory.rb,
lib/bluepill/util/rotational_array.rb,
lib/bluepill/process_conditions/http.rb,
lib/bluepill/process_conditions/cpu_usage.rb,
lib/bluepill/process_conditions/file_time.rb,
lib/bluepill/process_conditions/mem_usage.rb,
lib/bluepill/process_conditions/always_true.rb,
lib/bluepill/process_conditions/running_time.rb,
lib/bluepill/process_conditions/zombie_process.rb,
lib/bluepill/process_conditions/process_condition.rb

Defined Under Namespace

Modules: Application, ProcessConditions, ProcessJournal, Socket, System, Triggers, Util, Version Classes: AppProxy, ConditionWatch, Controller, Group, HistoryValue, Logger, Process, ProcessFactory, ProcessProxy, ProcessStatistics, Trigger

Class Method Summary collapse

Class Method Details

.application(app_name, options = {}, &block) ⇒ Object



2
3
4
5
6
7
8
9
10
# File 'lib/bluepill/dsl.rb', line 2

def self.application(app_name, options = {}, &block)
  app_proxy = AppProxy.new(app_name, options)
  if block.arity == 0
    app_proxy.instance_eval(&block)
  else
    app_proxy.instance_exec(app_proxy, &block)
  end
  app_proxy.app.load
end