]> git.donarmstrong.com Git - dsa-puppet.git/blob - modules/lvm/manifests/init.pp
luchesi -> ubc-bl4
[dsa-puppet.git] / modules / lvm / manifests / init.pp
1 class lvm {
2         case $::hostname {
3                 ubc-bl8,ubc-bl4: {
4                         $conffile = 'lvm-ubc-ganeti.conf'
5                 }
6                 ubc-bl3,ubc-bl7,ubc-bl2,ubc-bl6: {
7                         $conffile = 'lvm-ubc-ganeti-p410.conf'
8                 }
9                 csail-node01,csail-node02: {
10                         $conffile = 'lvm-csail-nodeX-ganeti.conf'
11                 }
12                 grnet-node01,grnet-node02: {
13                         $conffile = 'lvm-grnet-nodeX-ganeti.conf'
14                 }
15                 bm-bl1,bm-bl2,bm-bl3,bm-bl4,bm-bl5,bm-bl6,bm-bl7,bm-bl8,bm-bl9,bm-bl10,bm-bl11,bm-bl12: {
16                         $conffile = 'lvm-bm-blades.conf'
17                 }
18                 prokofiev: {
19                         $conffile = 'lvm-prokofiev.conf'
20                 }
21                 default: {
22                         $conffile = ''
23                 }
24         }
25
26         if $conffile != '' {
27                 package { 'lvm2':
28                         ensure => installed,
29                 }
30
31                 file { '/etc/lvm/lvm.conf':
32                         source  => "puppet:///modules/lvm/$conffile",
33                 }
34         }
35 }