Ales Komarek | 5fff552 | 2014-09-21 17:52:22 +0200 | [diff] [blame] | 1 | {%- from "isc_dhcp/map.jinja" import server with context %} |
| 2 | |
Ales Komarek | e653a10 | 2014-09-21 17:36:15 +0200 | [diff] [blame] | 3 | {%- for subnet_name, subnet in server.subnet.iteritems() %} |
| 4 | |
| 5 | subnet {{ subnet.network }} netmask {{ subnet.netmask }} { |
| 6 | {%- if subnet.range is defined %} |
jan kaufman | 821d3e9 | 2016-03-07 17:25:29 +0100 | [diff] [blame^] | 7 | range {{ subnet.range }}; |
Ales Komarek | e653a10 | 2014-09-21 17:36:15 +0200 | [diff] [blame] | 8 | {%- endif %} |
| 9 | |
| 10 | option subnet-mask {{ subnet.netmask }}; |
| 11 | {%- if subnet.gateway is defined %} |
| 12 | option routers {{ subnet.gateway }}; |
| 13 | {%- endif %} |
| 14 | {%- if subnet.pxeserver is defined %} |
| 15 | next-server {{ subnet.pxeserver }}; |
| 16 | {%- endif %} |
| 17 | } |
| 18 | |
jan kaufman | 821d3e9 | 2016-03-07 17:25:29 +0100 | [diff] [blame^] | 19 | {%- endfor %} |