class Luban::Deployment::Packages::Nginx::Installer

Public Instance Methods

installed?() click to toggle source
# File lib/luban/deployment/packages/nginx/installer.rb, line 16
def installed?
  return false unless file?(nginx_executable)
  pattern = "nginx version: nginx/#{package_major_version}"
  match?("#{nginx_executable} -v 2>&1", pattern)
end
source_repo() click to toggle source
# File lib/luban/deployment/packages/nginx/installer.rb, line 8
def source_repo
  @source_repo ||= "http://nginx.org"
end
source_url_root() click to toggle source
# File lib/luban/deployment/packages/nginx/installer.rb, line 12
def source_url_root
  @source_url_root ||= "download"
end
with_openssl_dir(dir)
Alias for: with_opt_dir
with_opt_dir(dir) click to toggle source
# File lib/luban/deployment/packages/nginx/installer.rb, line 22
def with_opt_dir(dir)
  @cc_opts << "-I #{dir.join('include')}"
  @ld_opts << "-L #{dir.join('lib')} -Wl,-rpath,#{dir.join('lib')}"
end
Also aliased as: with_pcre_dir, with_openssl_dir
with_pcre_dir(dir)
Alias for: with_opt_dir

Protected Instance Methods

compose_build_options() click to toggle source
Calls superclass method
# File lib/luban/deployment/packages/nginx/installer.rb, line 41
def compose_build_options
  @configure_opts << "--with-cc-opt=\"#{@cc_opts.join(' ')}\""
  @configure_opts << "--with-ld-opt=\"#{@ld_opts.join(' ')}\""
  super
end
configure_build_options() click to toggle source
Calls superclass method
# File lib/luban/deployment/packages/nginx/installer.rb, line 31
def configure_build_options
  super
  @configure_opts.unshift('--with-http_stub_status_module')
  @configure_opts.unshift('--with-stream')
  @configure_opts.unshift('--with-http_ssl_module')
  @configure_opts.unshift('--with-http_gzip_static_module')
  @cc_opts = []
  @ld_opts = []
end