virthost.conf.j2 630 B

12345678910111213
  1. <VirtualHost *:80>
  2. ServerName {{inventory_hostname_short}}.{{freifunk.domain}}
  3. ServerAdmin {{freifunk.email}}
  4. DocumentRoot /var/www/{{inventory_hostname_short}}.{{freifunk.domain}}
  5. ErrorLog ${APACHE_LOG_DIR}/{{inventory_hostname_short}}.{{freifunk.domain}}-error.log
  6. CustomLog ${APACHE_LOG_DIR}/{{inventory_hostname_short}}.{{freifunk.domain}}-access.log combined
  7. <Directory /var/www/{{inventory_hostname_short}}.{{freifunk.domain}}>
  8. Options -Indexes
  9. AllowOverride All
  10. </Directory>
  11. RewriteEngine On
  12. RewriteRule ^(.*)$ https://%{HTTP_HOST}$1 [R=301,L]
  13. </VirtualHost>