Sha256: 3f6e1afe89c20f7bda3ebecf507d1cfb6504e01c5c0f70e132fb7a142fd371d1

Contents?: true

Size: 1.54 KB

Versions: 8

Compression:

Stored size: 1.54 KB

Contents

Bluepill.application("app", :foreground => false, :log_file => "/var/log/bluepill.log") do |app|

  app.uid = "app"
  app.gid = "app"




  app.process("alpha-1") do |process|
    process.start_command = "./alpha"

    process.working_dir = "/tmp/app"
    process.daemonize = true
    process.environment = {"PORT" => "5000"}
    process.stop_signals = [:quit, 30.seconds, :term, 5.seconds, :kill]

    process.stdout = process.stderr = "/var/log/app/app-alpha-1.log"

    process.monitor_children do |children|
      children.stop_command "kill -QUIT {{PID}}"
    end
    
    process.group = "app-alpha"
  end


  app.process("alpha-2") do |process|
    process.start_command = "./alpha"

    process.working_dir = "/tmp/app"
    process.daemonize = true
    process.environment = {"PORT" => "5001"}
    process.stop_signals = [:quit, 30.seconds, :term, 5.seconds, :kill]

    process.stdout = process.stderr = "/var/log/app/app-alpha-2.log"

    process.monitor_children do |children|
      children.stop_command "kill -QUIT {{PID}}"
    end
    
    process.group = "app-alpha"
  end




  app.process("bravo-1") do |process|
    process.start_command = "./bravo"

    process.working_dir = "/tmp/app"
    process.daemonize = true
    process.environment = {"PORT" => "5100"}
    process.stop_signals = [:quit, 30.seconds, :term, 5.seconds, :kill]

    process.stdout = process.stderr = "/var/log/app/app-bravo-1.log"

    process.monitor_children do |children|
      children.stop_command "kill -QUIT {{PID}}"
    end
    
    process.group = "app-bravo"
  end


end

Version data entries

8 entries across 8 versions & 1 rubygems

Version Path
foreman-0.27.0 spec/resources/export/bluepill/app.pill
foreman-0.26.1 spec/resources/export/bluepill/app.pill
foreman-0.26.0 spec/resources/export/bluepill/app.pill
foreman-0.25.0 spec/resources/export/bluepill/app.pill
foreman-0.24.0 spec/resources/export/bluepill/app.pill
foreman-0.23.1 spec/resources/export/bluepill/app.pill
foreman-0.22.0 spec/resources/export/bluepill/app.pill
foreman-0.21.0 spec/resources/export/bluepill/app.pill