fix in rndc config and newline in yadyn logging

This commit is contained in:
Wolfgang Hottgenroth 2019-11-28 14:42:30 +01:00
parent 055afe70e3
commit 8ffa321312
Signed by: wn
GPG Key ID: 6C1E5E531E0D5D7F
2 changed files with 4 additions and 3 deletions

View File

@ -1,6 +1,6 @@
key "rndc-key" {
algorithm hmac-md5;
secret "$RNDCKEY";
secret "RNDCKEY";
};
controls {

View File

@ -1,17 +1,18 @@
import sys
import datetime
class Logger(object):
@staticmethod
def log(data):
with open(Logger.filename, 'a') as f:
f.write(data)
f.write(datetime.datetime.now().isoformat() + ' ' + data + "\n")
@staticmethod
def debug(data):
if Logger.debugFlag:
with open(Logger.filename, 'a') as f:
f.write(data)
f.write(datetime.datetime.now().isoformat() + ' ' + data + "\n")
@staticmethod
def openlog(filename):