pxe: Add option to determine status of dnsmasq tftp server
... so that all classes with service resources provide the consistent capability. Change-Id: Ic2f5d5140320f1a5921d5fa4984e6a8773aa304f
This commit is contained in:
parent
449150fd05
commit
d4627d4021
|
@ -25,6 +25,10 @@
|
|||
# (optional) Whether the service should be managed by Puppet.
|
||||
# Defaults to true.
|
||||
#
|
||||
# [*enabled*]
|
||||
# (optional) Define if the service must be enabled or not.
|
||||
# Defaults to true.
|
||||
#
|
||||
# [*tftp_root*]
|
||||
# (optional) Folder location to deploy PXE boot files
|
||||
# Defaults to '/tftpboot'
|
||||
|
@ -86,6 +90,7 @@
|
|||
class ironic::pxe (
|
||||
$package_ensure = 'present',
|
||||
$manage_service = true,
|
||||
$enabled = true,
|
||||
$tftp_root = '/tftpboot',
|
||||
$http_root = '/httpboot',
|
||||
$http_port = 8088,
|
||||
|
@ -210,10 +215,16 @@ class ironic::pxe (
|
|||
}
|
||||
|
||||
if $manage_service {
|
||||
if $enabled {
|
||||
$ensure = 'running'
|
||||
} else {
|
||||
$ensure = 'stopped'
|
||||
}
|
||||
|
||||
service { 'dnsmasq-tftp-server':
|
||||
ensure => 'running',
|
||||
ensure => $ensure,
|
||||
name => $::ironic::params::dnsmasq_tftp_service,
|
||||
enable => true,
|
||||
enable => $enabled,
|
||||
hasstatus => true,
|
||||
subscribe => File['/etc/ironic/dnsmasq-tftp-server.conf'],
|
||||
}
|
||||
|
|
|
@ -0,0 +1,5 @@
|
|||
---
|
||||
features:
|
||||
- |
|
||||
The new ``ironic::pxe::enabled`` parameter has been added. This parameter
|
||||
determines status of the dnsmasq tftp server service.
|
Loading…
Reference in New Issue