feat: add local pool

- the listening interface must match a subnet, or no service will start
This commit is contained in:
Ben Vincent 2025-06-29 11:55:32 +10:00
parent 3bb2a5dbad
commit 7b07626162
2 changed files with 11 additions and 0 deletions

View File

@ -8,3 +8,6 @@ vault::disable_mlock: true
# manage jellyfin changes
profiles::media::jellyfin::data_dir: /shared/apps/jellyfin
# dhcp-server requirements
profiles::dhcp::server::empty_local_pool: true

View File

@ -11,6 +11,7 @@ class profiles::dhcp::server (
Array[String] $globaloptions = [],
Hash $pools = {},
Hash $classes = {},
Boolean $empty_local_pool = false
){
if $facts['enc_role'] == 'roles::infra::dhcp::server' {
@ -35,5 +36,12 @@ class profiles::dhcp::server (
* => $data,
}
}
if $empty_local_pool {
dhcp::pool {'local':
network => $facts['networking']['interfaces'][$network_primary_interface]['network'],
mask => $facts['networking']['interfaces'][$network_primary_interface]['netmask'],
}
}
}
}