Add dhcp server to zm hosts
This commit is contained in:
parent
5df27ce9d5
commit
7cbdbfa43c
3 changed files with 40 additions and 0 deletions
38
roles/dhcpd/templates/dhcpd.conf.cam.j2
Normal file
38
roles/dhcpd/templates/dhcpd.conf.cam.j2
Normal file
|
@ -0,0 +1,38 @@
|
|||
|
||||
authorative;
|
||||
ddns-update-style none;
|
||||
|
||||
# logging
|
||||
on commit {
|
||||
log(info,
|
||||
concat("Client ",
|
||||
binary-to-ascii(16, 8, ":", substring(hardware, 1, 6)),
|
||||
" requests ",
|
||||
binary-to-ascii(16, 8, ":", option dhcp-parameter-request-list),
|
||||
" - ",
|
||||
pick-first-value(option vendor-class-identifier, "no vendor-id"),
|
||||
" - ",
|
||||
pick-first-value(option user-class, "no user-class"))
|
||||
);
|
||||
}
|
||||
|
||||
shared-network CAMNET {
|
||||
|
||||
subnet 172.20.26.0 netmask 255.255.255.0 {
|
||||
default-lease-time 86400;
|
||||
max-lease-time 604800;
|
||||
option subnet-mask 255.255.255.0;
|
||||
option broadcast-address 172.20.26.255;
|
||||
|
||||
option domain-name "cam.foo.sh";
|
||||
option domain-name-servers 172.20.26.1, 172.20.26.2, 172.20.26.3;
|
||||
use-host-decl-names on;
|
||||
}
|
||||
|
||||
host ipcam01.cam.foo.sh {
|
||||
option host-name "ipcam01.cam.foo.sh";
|
||||
hardware ethernet ec:71:db:6e:bc:0f;
|
||||
fixed-address 172.20.26.101;
|
||||
}
|
||||
|
||||
}
|
Loading…
Add table
Add a link
Reference in a new issue