Last change
on this file since 736 was
670,
checked in by sebas@…, 15 years ago
|
mandamos la variable del en lugar del path local
|
File size:
1.6 KB
|
Rev | Line | |
---|
[511] | 1 | class dnsmasq { |
---|
[513] | 2 | package { "dnsmasq": |
---|
| 3 | ensure => installed, |
---|
| 4 | } |
---|
[511] | 5 | } |
---|
| 6 | |
---|
| 7 | define dnsmasq::config ( |
---|
[537] | 8 | $dhcp_authoritative = 'absent', |
---|
| 9 | $dhcp_range = 'absent', |
---|
| 10 | $dhcp_gw = 'absent', |
---|
| 11 | $dhcp_nameservers = 'absent', |
---|
[557] | 12 | $dhcp_script = 'absent', |
---|
[559] | 13 | $dhcp_hostsfile = 'absent', |
---|
[561] | 14 | $addn_hosts = 'absent', |
---|
[537] | 15 | $domain = 'absent', |
---|
| 16 | $dhcp_boot = 'absent', |
---|
| 17 | $tftp_root = 'absent', |
---|
| 18 | $log_queries = 'absent', |
---|
| 19 | $log_dhcp = 'absent' |
---|
[511] | 20 | ) { |
---|
| 21 | |
---|
[513] | 22 | include dnsmasq |
---|
[511] | 23 | |
---|
[557] | 24 | file { |
---|
| 25 | "/etc/dnsmasq.d/my.dnsmasq.conf": |
---|
| 26 | content => template("dnsmasq/my.dnsmasq.conf.erb"), |
---|
| 27 | owner => root, |
---|
| 28 | group => root, |
---|
| 29 | mode => 644, |
---|
| 30 | require => Package["dnsmasq"], |
---|
| 31 | notify => Service["dnsmasq"]; |
---|
| 32 | "/etc/dnsmasq.hostsfile": |
---|
[559] | 33 | ensure => present, |
---|
[557] | 34 | owner => root, |
---|
| 35 | group => root, |
---|
[559] | 36 | mode => 644, |
---|
[557] | 37 | require => Package["dnsmasq"]; |
---|
| 38 | "/usr/local/sbin/dnsmasq-genhostname.sh": |
---|
[670] | 39 | source => "puppet://$servername/dnsmasq/dnsmasq-genhostname.sh", |
---|
[557] | 40 | owner => root, |
---|
| 41 | group => root, |
---|
| 42 | mode => 755, |
---|
| 43 | require => File["/etc/dnsmasq.hostsfile"]; |
---|
[561] | 44 | "/etc/hosts.dnsmasq": |
---|
| 45 | ensure => present, |
---|
| 46 | owner => root, |
---|
| 47 | group => root, |
---|
| 48 | mode => 644, |
---|
| 49 | require => Package["dnsmasq"]; |
---|
[557] | 50 | } |
---|
[511] | 51 | |
---|
| 52 | service { "dnsmasq": |
---|
[557] | 53 | ensure => running, |
---|
| 54 | hasrestart => true, |
---|
| 55 | hasstatus => true, |
---|
| 56 | require => File["/etc/dnsmasq.d/my.dnsmasq.conf"], |
---|
[511] | 57 | } |
---|
| 58 | |
---|
| 59 | } |
---|
Note: See
TracBrowser
for help on using the repository browser.