Puppet Class: classroom_legacy::agent::modulecache
- Defined in:
- manifests/agent/modulecache.pp
Overview
This module leverages the fact that we can add /usr/src/forge to our base- modulepath to automagically account for offline classes.
4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 |
# File 'manifests/agent/modulecache.pp', line 4
class classroom_legacy::agent::modulecache (
$config = '/etc/puppetlabs/puppet/puppet.conf',
$offline_bmp = '/etc/puppetlabs/code/modules:/usr/src/forge:/opt/puppetlabs/puppet/modules/',
) {
assert_private('This class should not be called directly')
$ensure = $::classroom_legacy::offline ? {
true => 'present',
default => 'absent',
}
case $::kernel {
'linux' : {
ini_setting { "offline basemodulepath" :
ensure => $ensure,
path => $config,
section => 'main',
setting => 'basemodulepath',
value => $offline_bmp,
}
}
# We don't have modules cached for Windows yet.
default : {}
}
}
|