source: trunk/puppet/modules/di_netboot_assistant/manifests/init.pp @ 421

Last change on this file since 421 was 395, checked in by sebas, 15 years ago

agrego el d-i para powerpc... a terminar

File size: 3.8 KB
Line 
1# copyright <sebas @ koumbit.org>
2# Licence: GPL
3#
4
5class di_netboot_assistant {
6
7   package { [ "di-netboot-assistant" ]: ensure => installed }
8
9   # sources.list with the lastest Ubuntu releases
10   file { "/etc/di-netboot-assistant/di-sources.list":
11      owner => root,
12      group => root,
13      mode => 644,
14      source => "puppet:///di_netboot_assistant/di-sources.list"
15   }
16
17   # some customization of the pxe menu
18   file { "/etc/di-netboot-assistant/pxelinux.HEAD":
19      owner => root,
20      group => root,
21      mode => 644,
22      source => "puppet:///di_netboot_assistant/pxelinux.HEAD"
23   }
24
25   # symbolic link to generated menu
26   file  { "/var/lib/tftpboot/pxelinux.cfg/default":
27      ensure => "../debian-installer/pxelinux.cfg/default"
28   }
29
30   exec { "di_netboot_assistant_lenny":
31      command => "di-netboot-assistant install lenny --arch=amd64,i386 &>/dev/null",
32      creates => "/var/lib/tftpboot/debian-installer/lenny/i386/linux",
33      path => "/bin:/sbin:/usr/sbin:/usr/bin",
34      require => [Package["di-netboot-assistant"], File["/etc/di-netboot-assistant/di-sources.list"], File["/etc/di-netboot-assistant/pxelinux.HEAD"]]
35   }
36
37   exec { "di_netboot_assistant_hardy":
38      command => "di-netboot-assistant install hardy --arch=amd64,i386 &>/dev/null",
39      creates => "/var/lib/tftpboot/debian-installer/hardy/i386/linux",
40      path => "/bin:/sbin:/usr/sbin:/usr/bin",
41      require => [Package["di-netboot-assistant"], exec["di_netboot_assistant_lenny"]]
42   }
43
44   exec { "di_netboot_assistant_jaunty":
45      command => "di-netboot-assistant install jaunty --arch=amd64,i386 &>/dev/null",
46      creates => "/var/lib/tftpboot/debian-installer/jaunty/i386/linux",
47      path => "/bin:/sbin:/usr/sbin:/usr/bin",
48      require => [Package["di-netboot-assistant"], exec["di_netboot_assistant_lenny"]]
49   }
50}
51
52class di_netboot_assistant::debian::powerpc::daily {
53
54    package { [ "tftpd-hpa" ]: ensure => installed }
55
56    file { ["/var/lib/tftpboot/debian-installer", "/var/lib/tftpboot/debian-installer/daily", "/var/lib/tftpboot/debian-installer/daily/powerpc/"]:
57      ensure => directory,
58      owner => root,
59      group => root,
60      require => Package["tftpd-hpa"];
61    }
62
63   fetch_netboot_powerpc { [ "boot.msg", "initrd.gz", "vmlinux", "yaboot", "yaboot.conf" ]:  }
64
65   $mirror_daily_di = "http://d-i.debian.org/daily-images/powerpc/daily/powerpc/netboot"
66
67   define fetch_netboot_powerpc($mirror = "http://d-i.debian.org/daily-images/powerpc/daily/powerpc/netboot") {
68
69#   file { ["/var/lib/tftpboot/debian-installer/daily1", "/var/lib/tftpboot/debian-installer/daily1/powerpc/"]:
70#      ensure => directory,
71#      owner => root,
72#      group => root,
73#      require => [Package["tftpd-hpa"]];
74#    }
75
76    exec { "wget -O /var/lib/tftpboot/debian-installer/daily/powerpc/$name -q $mirror1/$name":
77      creates => "/var/lib/tftpboot/debian-installer/daily/powerpc/$name",
78      path => "/usr/bin",
79      require => [Package["tftpd-hpa"], File["/var/lib/tftpboot/debian-installer/daily/powerpc/"]]
80    }
81   }
82}
83
84class di_netboot_assistant::debian::powerpc::squeeze {
85
86    file { ["/var/lib/tftpboot/debian-installer/squeeze", "/var/lib/tftpboot/debian-installer/squeeze/powerpc/"]:
87      ensure => directory,
88      owner => root,
89      group => root,
90      require => Package["tftpd-hpa"];
91    }
92
93   fetch_netboot_powerpc_squeeze { [ "boot.msg", "initrd.gz", "vmlinux", "yaboot", "yaboot.conf" ]:  }
94
95   define fetch_netboot_powerpc_squeeze($mirror = "http://debian.torredehanoi.org/debian/dists/squeeze/main/installer-powerpc/current/images/powerpc/netboot") {
96
97   exec { "wget -O /var/lib/tftpboot/debian-installer/squeeze/powerpc/$name -q $mirro1/$name":
98     creates => "/var/lib/tftpboot/debian-installer/squeeze/powerpc/$name",
99     path => "/usr/bin",
100     require => [Package["tftpd-hpa"], File["/var/lib/tftpboot/debian-installer/squeeze/powerpc/"]]
101   }
102  }
103}
Note: See TracBrowser for help on using the repository browser.