Last change
on this file since 559 was
559,
checked in by sebas@…, 14 years ago
|
agregamos el archivo para tener el listado de mac address + hostname + ip, esta usado por el script. +doc
|
File size:
1.4 KB
|
Line | |
---|
1 | class dnsmasq { |
---|
2 | package { "dnsmasq": |
---|
3 | ensure => installed, |
---|
4 | } |
---|
5 | } |
---|
6 | |
---|
7 | define dnsmasq::config ( |
---|
8 | $dhcp_authoritative = 'absent', |
---|
9 | $dhcp_range = 'absent', |
---|
10 | $dhcp_gw = 'absent', |
---|
11 | $dhcp_nameservers = 'absent', |
---|
12 | $dhcp_script = 'absent', |
---|
13 | $dhcp_hostsfile = 'absent', |
---|
14 | $domain = 'absent', |
---|
15 | $dhcp_boot = 'absent', |
---|
16 | $tftp_root = 'absent', |
---|
17 | $log_queries = 'absent', |
---|
18 | $log_dhcp = 'absent' |
---|
19 | ) { |
---|
20 | |
---|
21 | include dnsmasq |
---|
22 | |
---|
23 | file { |
---|
24 | "/etc/dnsmasq.d/my.dnsmasq.conf": |
---|
25 | content => template("dnsmasq/my.dnsmasq.conf.erb"), |
---|
26 | owner => root, |
---|
27 | group => root, |
---|
28 | mode => 644, |
---|
29 | require => Package["dnsmasq"], |
---|
30 | notify => Service["dnsmasq"]; |
---|
31 | "/etc/dnsmasq.hostsfile": |
---|
32 | ensure => present, |
---|
33 | owner => root, |
---|
34 | group => root, |
---|
35 | mode => 644, |
---|
36 | require => Package["dnsmasq"]; |
---|
37 | "/usr/local/sbin/dnsmasq-genhostname.sh": |
---|
38 | source => "puppet:///dnsmasq/dnsmasq-genhostname.sh", |
---|
39 | owner => root, |
---|
40 | group => root, |
---|
41 | mode => 755, |
---|
42 | require => File["/etc/dnsmasq.hostsfile"]; |
---|
43 | } |
---|
44 | |
---|
45 | service { "dnsmasq": |
---|
46 | ensure => running, |
---|
47 | hasrestart => true, |
---|
48 | hasstatus => true, |
---|
49 | require => File["/etc/dnsmasq.d/my.dnsmasq.conf"], |
---|
50 | } |
---|
51 | |
---|
52 | } |
---|
Note: See
TracBrowser
for help on using the repository browser.