module Luban::Deployment::Packages::Nginx::Controller::Commands
Public Class Methods
included(base)
click to toggle source
# File lib/luban/deployment/packages/nginx/controller.rb, line 7 def self.included(base) base.define_executable 'nginx' end
Public Instance Methods
bin_path()
click to toggle source
# File lib/luban/deployment/packages/nginx/controller.rb, line 11 def bin_path @bin_path ||= install_path.join('sbin') end
nginx_command()
click to toggle source
# File lib/luban/deployment/packages/nginx/controller.rb, line 15 def nginx_command @nginx_command ||= "#{nginx_executable} -c #{control_file_path}" end
process_pattern()
click to toggle source
# File lib/luban/deployment/packages/nginx/controller.rb, line 19 def process_pattern @process_pattern ||= "^nginx: master process #{nginx_command}" end
start_command()
click to toggle source
# File lib/luban/deployment/packages/nginx/controller.rb, line 23 def start_command @start_command ||= shell_command(nginx_command) end
stop_command()
click to toggle source
# File lib/luban/deployment/packages/nginx/controller.rb, line 27 def stop_command @stop_command ||= shell_command("#{nginx_command} -s stop") end