Method: PlatformInfo.httpd

Defined in:
lib/phusion_passenger/platform_info.rb

.httpdObject

The absolute path to the Apache binary (that is, ‘httpd’, ‘httpd2’, ‘apache’ or ‘apache2’).



240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
# File 'lib/phusion_passenger/platform_info.rb', line 240

def self.httpd
  if env_defined?('HTTPD')
    return ENV['HTTPD']
  elsif apxs2.nil?
    ["apache2", "httpd2", "apache", "httpd"].each do |name|
      command = find_command(name)
      if !command.nil?
        return command
      end
    end
    return nil
  else
    return find_apache2_executable(`#{apxs2} -q TARGET`.strip)
  end
end