| Module | geoip |
| In: |
/modules/geoip/manifests/common.pp
/modules/geoip/manifests/file.pp /modules/geoip/manifests/conf.pp |
Install any of the GeoIP database files.
There is no magic here, you need to have the Geo*.dat files available on your puppetmaster somewhere, and reference them. This module is only a minor convenience, since using the "file" type over and over with hardcoded paths gets quite ugly.
Example :
# In site.pp :
Geoip::File {
path => '/usr/local/share',
source_path => 'puppet:///modules/mymodule/GeoIP',
}
# For a node where nginx will have its geoip module enabled :
geoip::file { 'GeoIP.dat': before => Class['nginx'] }
Class: geoip::file
Install any of the GeoIP database files.
Parameters:
$ensure: Whether the file should be 'present' or 'absent'. Defaults to 'present'. $path: Full path where to install the file to. Default: /usr/share/GeoIP $source_path: Puppet path prefix where to find the source file. Mandatory.
Sample Usage :
Geoip::File { source_path => 'puppet:///modules/foo/GeoIP' }
geoip::file { [ 'GeoIP.dat', 'GeoIPv6.dat' ]: }