X-Git-Url: https://git.adam-barratt.org.uk/?a=blobdiff_plain;f=modules%2Fganeti2%2Fmanifests%2Finit.pp;h=5e03c24123b4a418ba216af52f617af6c8e81a2a;hb=821837e1e054003f4431e81da6b24639c41b2a78;hp=33f9c2107fe30fc5c6d6f16117bde99ceef2109c;hpb=dfd572c2f7cc99584b197f63d97a6181283b670f;p=mirror%2Fdsa-puppet.git diff --git a/modules/ganeti2/manifests/init.pp b/modules/ganeti2/manifests/init.pp index 33f9c2107..5e03c2412 100644 --- a/modules/ganeti2/manifests/init.pp +++ b/modules/ganeti2/manifests/init.pp @@ -1,3 +1,11 @@ +# = Class: ganeti2 +# +# Standard ganeti2 config debian.org hosts +# +# == Sample Usage: +# +# include ganeti2 +# class ganeti2 { include ganeti2::params @@ -9,68 +17,32 @@ class ganeti2 { ensure => installed } - package { 'ganeti-instance-debootstrap': - ensure => installed - } + site::linux_module { 'tun': } - package { 'ganeti-htools': - ensure => installed + file { '/etc/cron.hourly/puppet-cleanup-watcher-pause-file': + source => 'puppet:///modules/ganeti2/cleanup-watcher-pause-file', + mode => '0555', } - if $drbd { - package { 'drbd8-utils': - ensure => installed + if $::debarchitecture == 'arm64' { + file { '/usr/local/bin/qemu-system-aarch64-wrapper': + source => 'puppet:///modules/ganeti2/qemu-system-aarch64-wrapper', + mode => '0555', } } - - site::linux_module { 'tun': } - - file { - '/etc/ganeti/instance-debootstrap/variants.list': - content => template('ganeti2/instance-debootstrap/variants.list.erb'), - require => Package['ganeti-instance-debootstrap'], - ; - '/etc/ganeti/instance-debootstrap/variants/dsa.conf': - content => template('ganeti2/instance-debootstrap/variants/dsa.conf.erb'), - require => Package['ganeti-instance-debootstrap'], - ; - '/etc/ganeti/instance-debootstrap/variants/dsa-wheezy.conf': - content => template('ganeti2/instance-debootstrap/variants/dsa-wheezy.conf.erb'), - require => Package['ganeti-instance-debootstrap'], - ; - '/etc/ganeti/instance-debootstrap/hooks/00-dsa-configure-networking': - content => template('ganeti2/instance-debootstrap/hooks/00-dsa-configure-networking.erb'), - require => Package['ganeti-instance-debootstrap'], + if $::cluster == 'ganeti.bm.debian.org' { + file { '/usr/local/sbin/crazy-multipath-restart': + source => 'puppet:///modules/ganeti2/crazy-multipath-restart', mode => '0555', - ; - '/etc/ganeti/instance-debootstrap/hooks/10-dsa-install-extra-packages': - content => template('ganeti2/instance-debootstrap/hooks/10-dsa-install-extra-packages.erb'), - require => Package['ganeti-instance-debootstrap'], - mode => '0555', - ; - '/etc/ganeti/instance-debootstrap/hooks/20-dsa-install-bootloader': - content => template('ganeti2/instance-debootstrap/hooks/20-dsa-install-bootloader.erb'), - require => Package['ganeti-instance-debootstrap'], - mode => '0555', - ; - '/etc/ganeti/instance-debootstrap/hooks/30-dsa-install-ssh-keys': - content => template('ganeti2/instance-debootstrap/hooks/30-dsa-install-ssh-keys.erb'), - require => Package['ganeti-instance-debootstrap'], - mode => '0555', - ; - '/etc/ganeti/instance-debootstrap/hooks/40-dsa-setup-swapfile': - content => template('ganeti2/instance-debootstrap/hooks/40-dsa-setup-swapfile.erb'), - require => Package['ganeti-instance-debootstrap'], - mode => '0555', - ; - '/etc/ganeti/instance-debootstrap/hooks/clear-root-password': - require => Package['ganeti-instance-debootstrap'], - mode => '0444', - ; - '/etc/ganeti/instance-debootstrap/hooks/xen-hvc0': - require => Package['ganeti-instance-debootstrap'], - mode => '0444', - ; + } + file { '/etc/cron.d/puppet-crazy-multipath-restart': + ensure => absent, + } + concat::fragment { 'dsa-puppet-stuff--multipath-restart': + target => '/etc/cron.d/dsa-puppet-stuff', + content => @("EOF"), + */15 * * * * root /usr/local/sbin/crazy-multipath-restart + | EOF + } } - }