Created
April 21, 2016 09:59
-
-
Save packetninja/b1f5656828fbe5157dbc0d96ba07db05 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
{{ header_tmpl }} | |
{%- set dhcpvars = dhcp -%} | |
# | |
# dhcpd.conf | |
# | |
authoritative; | |
allow booting; | |
allow bootp; | |
default-lease-time 86400; | |
max-lease-time 604800; | |
log-facility local7; | |
ddns-update-style none; | |
# | |
# Options | |
# | |
option domain-name "cl-management.local"; | |
option domain-name-servers 172.30.1.1; | |
option cumulus-provision-url code 239 = text; | |
# | |
# Subnets | |
# | |
subnet 172.30.1.0 netmask 255.255.255.0 { | |
range 172.30.1.100 172.30.1.200; | |
option subnet-mask 255.255.255.0; | |
option routers 172.30.1.1; | |
option default-url = "http://172.30.1.1/onie-installer"; | |
option cumulus-provision-url "http://172.30.1.1/provisioning.sh"; | |
} | |
{% for host in dhcpvars.keys() %} | |
host {{ host }} { | |
option host-name "{{ host }}"; | |
hardware ethernet {{ dhcpvars[host].mac }}; | |
fixed-address 172.30.1.{{ dhcpvars[host].lastoctet }}; | |
} | |
{% endfor %} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment