diff options
Diffstat (limited to 'router.py')
| -rw-r--r-- | router.py | 7 |
1 files changed, 6 insertions, 1 deletions
@@ -15,7 +15,10 @@ import random from collections import defaultdict, deque import zmq -from helpers import CustomLoggingFormatter +from helpers import ( + CustomLoggingFormatter, + auth_service, +) # TODO: add configparser @@ -38,6 +41,7 @@ if not os.path.exists(LOGDID): BASENAME = f"{os.path.splitext(os.path.basename(__file__))[0]}" LOGFILE = os.path.join(LOGDID, f"{BASENAME}.log") LOGLEVEL = logging.INFO +CERTIFICATE_DIRECTORY = 'certs' log_formatter = CustomLoggingFormatter() handler = logging.FileHandler(LOGFILE, encoding='utf-8', mode='a') @@ -67,6 +71,7 @@ def custom_proxy() -> None: None """ context = zmq.Context.instance() + auth_service(context, CERTIFICATE_DIRECTORY) poller = zmq.Poller() # Set up frontend: |
