Using custom variable to assign value to bootfile-name

Simon Hobson dhcp1 at thehobsons.co.uk
Wed Nov 11 22:42:55 UTC 2015


Niall O'Reilly <niall.oreilly at ucd.ie> wrote:

>  Variables don't do what you need.
> 
>  I'ld suggest something like this, repeated for the other groups:
> 
> group target_1 {
>  option boot-filename = "soft_1.tar";
> }

I think the problem he has is that if he allows the devs to edit that themselves, they screw up the rest of the config. I'm wondering if some include files (and perhaps some scripts) might work.

group target_1 {
 $INCLUDE soft1.cfg
}

Then generate a number of config files that you can use with the include statements. Either let the devs edit them directly, or let them work through a script that does some sanity checking.

Or put placeholders in the config, and have a script that replaces them with the desired values to generate a config file for the server to use.



More information about the dhcp-users mailing list