1 #!/bin/sh i like colors :)
3 # the following variables are available in the template:
5 # $INTERFACE_ (interface for the terminalserver)
6 # $IP_ (ip for the terminalserver to bind)
7 # $NETMASK_ (network mask)
9 # $NAMESERVERS_ (nameservers for the nodes)
10 # $IPRANGE_FROM_ (user configured iprange, first ip)
11 # $IPRANGE_TO_ (user configured iprange, last ip)
12 # $NETWORK_ (first ip in this subnet)
13 # $OPTIONS_ (options for grml-terminalserver)
14 # $BOOT_ARGS_ (boot arguments for the nodes)
17 # templates are shellscript fragments and will be sourced from the
23 # this is the template to create the config file for the dhcpd server
26 date_=`execute date warn`
28 cat >"$DHCPD_CONFIG_FILE_" <<EOT
29 # ${DHCPD_CONFIG_FILE_##/*/} for GRML terminalserver
31 # THIS IS A GENERATED CONFIG FROM GRML-TERMINALSERVER, DO NOT EDIT!!!
32 # better adapt $TEMPLATE_CONFIG_DIR_/dhcpd_config to your needs and update config
33 # with grml-terminalserver config dhcp
35 # If you really want to edit _this_ file remove the next line
36 # __PLEASE_UPDATE_THIS_FILE__
41 #option option-150 code 150 = text ;
42 #option T150 code 150 = string;
43 default-lease-time 600;
46 subnet $NETWORK_ netmask $NETMASK_ {
48 if substring (option vendor-class-identifier, 0, 9) = "Etherboot" { filename "etherboot.nbi"; }
49 else { filename "pxelinux.0"; }
50 # option subnet-mask $NETMASK_;
51 range $IPRANGE_FROM_ $IPRANGE_TO_;
52 # option T150 "/menu.lst";
53 # option option-150 "(nd)/menu.lst";