system-config/modules/meetbot/templates/vhost.erb
Jeremy Stanley 67b91c1606 Serve IRC log files as MIME type text/plain.
* modules/meetbot/manifests/site.pp: Specify a nondefault vhost
template.

* modules/meetbot/templates/vhost.erb: New file, similar in content
to the default puppetlabs-apache vhost template but forcing MIME
type text/plain and a default encoding of UTF-8 for files ending in
a .log suffix.

Change-Id: Ief0253c2baac32b126472d0f97f0aa503adbbd7f
2013-07-20 20:36:32 +00:00

30 lines
833 B
Plaintext

# ************************************
# Managed by Puppet
# ************************************
NameVirtualHost <%= vhost_name %>:<%= port %>
<VirtualHost <%= vhost_name %>:<%= port %>>
ServerName <%= srvname %>
<% if serveraliases.is_a? Array -%>
<% serveraliases.each do |name| -%><%= " ServerAlias #{name}\n" %><% end -%>
<% elsif serveraliases != '' -%>
<%= " ServerAlias #{serveraliases}" %>
<% end -%>
DocumentRoot <%= docroot %>
<FilesMatch \.log$>
ForceType text/plain
AddDefaultCharset UTF-8
</FilesMatch>
<Directory <%= docroot %>>
Options <%= options %>
AllowOverride None
Order allow,deny
allow from all
</Directory>
ErrorLog /var/log/apache2/<%= name %>_error.log
LogLevel warn
CustomLog /var/log/apache2/<%= name %>_access.log combined
ServerSignature Off
</VirtualHost>