remove puppet 0.24 support
Introduction of stdlib functions makes support of puppet < 2.7 impractical.
This commit is contained in:
parent
6e554e1a26
commit
cca9401844
3 changed files with 1 additions and 23 deletions
|
@ -83,7 +83,6 @@ define concat(
|
|||
|
||||
$safe_name = regsubst($name, '/', '_', 'G')
|
||||
$concatdir = $concat::setup::concatdir
|
||||
$version = $concat::setup::majorversion
|
||||
$fragdir = "${concatdir}/${safe_name}"
|
||||
$concat_name = 'fragments.concat.out'
|
||||
$default_warn_message = '# This file is managed by Puppet. DO NOT EDIT.'
|
||||
|
@ -131,11 +130,6 @@ define concat(
|
|||
replace => $replace
|
||||
}
|
||||
|
||||
$source_real = $version ? {
|
||||
24 => 'puppet:///concat/null',
|
||||
default => undef,
|
||||
}
|
||||
|
||||
if $ensure == 'present' {
|
||||
file { $fragdir:
|
||||
ensure => directory,
|
||||
|
@ -148,7 +142,6 @@ define concat(
|
|||
notify => Exec["concat_${name}"],
|
||||
purge => true,
|
||||
recurse => true,
|
||||
source => $source_real,
|
||||
}
|
||||
|
||||
file { "${fragdir}/fragments.concat":
|
||||
|
|
|
@ -7,14 +7,6 @@
|
|||
# Since puppet should always manage files in $concatdir and they should
|
||||
# not be deleted ever, /tmp is not an option.
|
||||
#
|
||||
# [$puppetversion]
|
||||
# should be either 24 or 25 to enable a 24 compatible
|
||||
# mode, in 24 mode you might see phantom notifies this is a side effect
|
||||
# of the method we use to clear the fragments directory.
|
||||
#
|
||||
# The regular expression below will try to figure out your puppet version
|
||||
# but this code will only work in 0.24.8 and newer.
|
||||
#
|
||||
# It also copies out the concatfragments.sh file to ${concatdir}/bin
|
||||
#
|
||||
class concat::setup {
|
||||
|
@ -30,17 +22,11 @@ class concat::setup {
|
|||
fail ('$concat_basedir not defined. Try running again with pluginsync=true on the [master] and/or [main] section of your node\'s \'/etc/puppet/puppet.conf\'.')
|
||||
}
|
||||
|
||||
$majorversion = regsubst($::puppetversion, '^[0-9]+[.]([0-9]+)[.][0-9]+$', '\1')
|
||||
$fragments_source = $majorversion ? {
|
||||
24 => 'puppet:///concat/concatfragments.sh',
|
||||
default => 'puppet:///modules/concat/concatfragments.sh'
|
||||
}
|
||||
|
||||
file { "${concatdir}/bin/concatfragments.sh":
|
||||
owner => $id,
|
||||
group => $root_group,
|
||||
mode => '0755',
|
||||
source => $fragments_source,
|
||||
source => 'puppet:///modules/concat/concatfragments.sh',
|
||||
}
|
||||
|
||||
file { [ $concatdir, "${concatdir}/bin" ]:
|
||||
|
|
|
@ -58,7 +58,6 @@ describe 'concat', :type => :define do
|
|||
:ignore => ['.svn', '.git', '.gitignore'],
|
||||
:purge => true,
|
||||
:recurse => true,
|
||||
:source => nil, # true for all but for puppet 24
|
||||
}))
|
||||
end
|
||||
|
||||
|
|
Loading…
Reference in a new issue