Commit d57c1502 authored by Andreas Kempe's avatar Andreas Kempe
Browse files

Add named configuration reload

When a new key is added to named, we need to reload the configuration
for it to be used.
parent 5966d22b
......@@ -140,5 +140,9 @@ def application(env, start_response):
with open("/usr/local/etc/namedb/master/" + domain_name, "w") as zonefile_file:
# Reload bind config to import new keys
if os.system('/usr/local/sbin/rndc reload') != 0:
print('Could not restart named!')
start_response('200 OK', [('Content-Type', 'text/html')])
return [b""]
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment