1 | # |
---|
2 | # Example usage with a proxy of packages: |
---|
3 | # ltsp::buildclient { dist: |
---|
4 | # mirror => "http://debproxy:3142/ar.archive.ubuntu.com/ubuntu", |
---|
5 | # securitymirror => "http://debproxy:3142/security.ubuntu.com" |
---|
6 | # } |
---|
7 | # |
---|
8 | # to debug inside ltsp client |
---|
9 | # chroot /opt/ltsp/i386 |
---|
10 | # mount /proc -t proc /proc && mount /sys -t sysfs /sys |
---|
11 | |
---|
12 | ## TODO: |
---|
13 | # - set root password |
---|
14 | # - configure munin-node |
---|
15 | |
---|
16 | class ltsp::common { |
---|
17 | package { "ltsp-server": ensure => installed } |
---|
18 | package { "ltspfs": ensure => installed } |
---|
19 | } |
---|
20 | |
---|
21 | define ltsp::buildclient ( $mirror, $securitymirror ) { |
---|
22 | include ltsp::common |
---|
23 | exec { "ltsp-build-client": |
---|
24 | command => "ltsp-build-client --mirror=$mirror --security-mirror=$securitymirror --late-packages \"ssh munin-node\" &>/dev/null", |
---|
25 | path => "/bin:/sbin:/usr/sbin:/usr/bin", |
---|
26 | creates => "/opt/ltsp/i386", |
---|
27 | } |
---|
28 | } |
---|
29 | |
---|
30 | |
---|
31 | class ltsp::tftpdhpa::activate { |
---|
32 | package { "tftpd-hpa": ensure => installed } |
---|
33 | |
---|
34 | line { tftpdhpa_activate_off: |
---|
35 | file => "/etc/default/tftpd-hpa", |
---|
36 | line => 'RUN_DAEMON="no"', |
---|
37 | ensure => absent, |
---|
38 | require => Package["tftpd-hpa"] |
---|
39 | } |
---|
40 | |
---|
41 | line { tftpdhpa_activate_on: |
---|
42 | file => "/etc/default/tftpd-hpa", |
---|
43 | line => 'RUN_DAEMON="yes"', |
---|
44 | ensure => present, |
---|
45 | require => Package["tftpd-hpa"] |
---|
46 | } |
---|
47 | } |
---|
48 | |
---|