forked from p34709852/monkey
Added expand user call to transform data dir input into a proper path
This commit is contained in:
parent
559b61b581
commit
36b3e987da
|
@ -1,5 +1,7 @@
|
|||
from __future__ import annotations
|
||||
|
||||
import os
|
||||
|
||||
from monkey_island.cc.server_utils.consts import (
|
||||
DEFAULT_DATA_DIR,
|
||||
DEFAULT_LOG_LEVEL,
|
||||
|
@ -9,7 +11,7 @@ from monkey_island.cc.server_utils.consts import (
|
|||
|
||||
class IslandConfigOptions:
|
||||
def __init__(self, config_contents: dict):
|
||||
self.data_dir = config_contents.get("data_dir", DEFAULT_DATA_DIR)
|
||||
self.data_dir = os.path.expanduser(config_contents.get("data_dir", DEFAULT_DATA_DIR))
|
||||
|
||||
self.log_level = config_contents.get("log_level", DEFAULT_LOG_LEVEL)
|
||||
|
||||
|
|
Loading…
Reference in New Issue