diff options
author | Raphaël Pinson <raphael.pinson@camptocamp.com> | 2013-04-14 23:50:03 -0700 |
---|---|---|
committer | Raphaël Pinson <raphael.pinson@camptocamp.com> | 2013-04-14 23:50:03 -0700 |
commit | 93895f1f039956ec9d02df511aaeaed885ae34bf (patch) | |
tree | 704909c98dc11bb9206b2c67f3f8557418507a21 /manifests/server/service.pp | |
parent | 87162a8cc3e47996160f85e1807f75b9ad741bc8 (diff) | |
parent | c0f46562b70777b9a4a39429d94c49e869150c64 (diff) | |
download | puppet-dhcp-93895f1f039956ec9d02df511aaeaed885ae34bf.tar.gz puppet-dhcp-93895f1f039956ec9d02df511aaeaed885ae34bf.tar.bz2 |
Merge pull request #5 from raphink/dev/cleanup
Cleanup, refactor…
Diffstat (limited to 'manifests/server/service.pp')
-rw-r--r-- | manifests/server/service.pp | 19 |
1 files changed, 19 insertions, 0 deletions
diff --git a/manifests/server/service.pp b/manifests/server/service.pp new file mode 100644 index 0000000..ef016c5 --- /dev/null +++ b/manifests/server/service.pp @@ -0,0 +1,19 @@ +# Class: dhcp::server::service +# +# Manage the DHCP server service +# +class dhcp::server::service { + include ::dhcp::params + + validate_string($dhcp::params::srv_dhcpd) + validate_re($dhcp::params::srv_dhcpd, '^\S+$') + validate_string($dhcp::params::service_pattern) + validate_re($dhcp::params::service_pattern, '^\S+$') + + service {'dhcpd': + ensure => running, + name => $dhcp::params::srv_dhcpd, + enable => true, + pattern => $dhcp::params::service_pattern, + } +} |