apache-config-generator/lib/apache/ssl.rb

19 lines
454 B
Ruby
Raw Normal View History

2010-05-10 21:43:34 +00:00
module Apache
module SSL
def enable_ssl_engine(options = {})
self << ""
self << "SSLEngine on"
2010-05-12 18:24:35 +00:00
options.each do |key, value|
value = quoteize(value).first
case key
2010-05-10 21:43:34 +00:00
when :certificate_file, :certificate_key_file
2010-05-18 16:43:57 +00:00
self << "SSL#{key.apachify} #{value}"
2010-05-10 21:43:34 +00:00
when :ca_certificate_file
2010-05-12 18:24:35 +00:00
self << "SSLCACertificateFile #{value}"
2010-05-10 21:43:34 +00:00
end
end
self << ""
end
end
end