aboutsummaryrefslogtreecommitdiff
path: root/manifests/shared-network.pp
blob: 9a02a5b8eb57eaa2cc585f4e4cfd83618e7c797d (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
# == Definition: dhcp::shared-network
# Creates a shared-network
#
# Arguments:
#  *$subnets* : subnet list to be included in the shared-network
#
# Warnings:
#  - subnets must exists
#  - subnets must have $is_shared set to true (default is false)
#
define dhcp::shared-network(
  $ensure  = present,
  $subnets = []
) {

  include dhcp::params

  concat::fragment {"shared-${name}":
    ensure  => $ensure,
    target  => "${dhcp::params::config_dir}/dhcpd.conf",
    content => template('dhcp/shared-network.erb'),
    require => Dhcp::Subnet[$subnets],
  }

}