secure 29.172.in-addr.arpa
[mirror/dsa-puppet.git] / modules / roles / manifests / static_mirror.pp
index 1aa20d7..8dd1bb8 100644 (file)
@@ -2,13 +2,14 @@ class roles::static_mirror {
 
        include roles::static_source
 
-       package { 'libapache2-mod-macro':
-               ensure => installed,
-       }
+       package { 'libapache2-mod-macro': ensure => installed, }
+       package { 'libapache2-mod-geoip': ensure => installed, }
+       package { 'geoip-database': ensure => installed, }
 
        apache2::module { 'macro': require => Package['libapache2-mod-macro']; }
        apache2::module { 'rewrite': }
        apache2::module { 'expires': }
+       apache2::module { 'geoip': require => [Package['libapache2-mod-geoip'], Package['geoip-database']]; }
 
        file { '/usr/local/bin/static-mirror-run':
                source => 'puppet:///modules/roles/static-mirroring/static-mirror-run',
@@ -31,8 +32,17 @@ class roles::static_mirror {
                default => '*:80',
        }
 
+       apache2::config { "local-static-vhost.conf":
+               content => template('roles/static-mirroring/static-vhost.conf.erb'),
+       }
+
        apache2::site { '010-planet.debian.org':
                site    => 'planet.debian.org',
                content => template('roles/static-mirroring/vhost/planet.debian.org.erb'),
        }
+
+       apache2::site { '010-static-vhosts-simple':
+               site => "static-vhosts-simple",
+               content => template('roles/static-mirroring/vhost/static-vhosts-simple.erb'),
+       }
 }