X-Git-Url: https://git.adam-barratt.org.uk/?a=blobdiff_plain;f=modules%2Fdebian_org%2Fmanifests%2Finit.pp;h=db17a742d20011f2919f81714fa557348f1a1672;hb=731c86b98743b06f4c3612b0ec9d3df2158126cc;hp=1472f308d81708d3aa3f95756f76040cb5203d01;hpb=4999970bbdafaa82d0baa4dc6b8c0901c82214d0;p=mirror%2Fdsa-puppet.git diff --git a/modules/debian_org/manifests/init.pp b/modules/debian_org/manifests/init.pp index 1472f308d..db17a742d 100644 --- a/modules/debian_org/manifests/init.pp +++ b/modules/debian_org/manifests/init.pp @@ -41,12 +41,6 @@ class debian_org { ensure => installed, tag => extra_repo, } - file { '/etc/ssh/ssh_known_hosts': - ensure => present, - replace => false, - mode => '0644', - source => 'puppet:///modules/debian_org/basic-ssh_known_hosts' - } if versioncmp($::lsbmajdistrelease, '8') >= 0 { $rubyfs_package = 'ruby-filesystem' @@ -351,10 +345,27 @@ class debian_org { } # Disable kpartx udev rules - if $has_lib_udev_rules_d_60_kpartx_rules { - file { '/etc/udev/rules.d/60-kpartx.rules': - content => "", - mode => '0444', + file { '/etc/udev/rules.d/60-kpartx.rules': + ensure => $has_lib_udev_rules_d_60_kpartx_rules ? { true => 'present', default => 'absent' }, + content => "", + mode => '0444', + } + + # this is only to avoid warnings, else puppet will complain that we + # have a symlink there, even if we're not replacing it anyhow. + if ! $has_etc_ssh_ssh_known_hosts { + file { '/etc/ssh/ssh_known_hosts': + ensure => 'present', + replace => 'no', + content => inline_template('<%= open("/etc/ssh/ssh_known_hosts").read() %>'), + notify => Exec['ud-replicate'], } } + + exec { 'ud-replicate': + path => '/usr/bin:/usr/sbin:/bin:/sbin', + command => '/usr/bin/ud-replicate', + refreshonly => true, + require => Package['userdir-ldap'] + } }