mirror of
https://github.com/Cian-H/I-Form_Server_Node_Deployer.git
synced 2025-12-22 22:22:02 +00:00
restructured project to have /src folder
This commit is contained in:
@@ -11,6 +11,7 @@ import docker
|
|||||||
|
|
||||||
|
|
||||||
CLIENT = docker.from_env(version="auto")
|
CLIENT = docker.from_env(version="auto")
|
||||||
|
ROOT = Path(__file__).parent.parent
|
||||||
|
|
||||||
type ConfigLabel = str | list[str]
|
type ConfigLabel = str | list[str]
|
||||||
|
|
||||||
@@ -18,7 +19,7 @@ type ConfigLabel = str | list[str]
|
|||||||
def get_config(config_label: ConfigLabel = ["default"]) -> dict:
|
def get_config(config_label: ConfigLabel = ["default"]) -> dict:
|
||||||
if isinstance(config_label, str):
|
if isinstance(config_label, str):
|
||||||
config_label = [config_label]
|
config_label = [config_label]
|
||||||
with open("config.toml", "rb") as f:
|
with open(ROOT / "config.toml", "rb") as f:
|
||||||
configs: dict = tomllib.load(f)
|
configs: dict = tomllib.load(f)
|
||||||
out_config: dict = {}
|
out_config: dict = {}
|
||||||
for c in config_label:
|
for c in config_label:
|
||||||
Reference in New Issue
Block a user