From cee2250c5a52a4d67ea2a37cc97761ba530f856b Mon Sep 17 00:00:00 2001 From: =?utf8?q?Ale=C5=A1=20Mr=C3=A1zek?= Date: Wed, 19 Feb 2025 13:13:49 +0100 Subject: [PATCH] python: constants: added API_SOCKET_NAME --- python/knot_resolver/constants.py | 9 ++++++--- python/knot_resolver/constants.py.in | 9 ++++++--- 2 files changed, 12 insertions(+), 6 deletions(-) diff --git a/python/knot_resolver/constants.py b/python/knot_resolver/constants.py index e562d6253..560e7697c 100644 --- a/python/knot_resolver/constants.py +++ b/python/knot_resolver/constants.py @@ -5,15 +5,18 @@ VERSION = "6.0.10" USER = "knot-resolver" GROUP = "knot-resolver" -# dirs paths +# default files names +API_SOCK_NAME = "kres-api.sock" + +# default dirs paths RUN_DIR = Path("/run/knot-resolver") ETC_DIR = Path("/etc/knot-resolver") SBIN_DIR = Path("/usr/sbin") CACHE_DIR = Path("/var/cache/knot-resolver") -# files paths +# default files paths CONFIG_FILE = ETC_DIR / "config.yaml" -API_SOCK_FILE = RUN_DIR / "kres-api.sock" +API_SOCK_FILE = RUN_DIR / API_SOCK_NAME # executables paths KRESD_EXECUTABLE = SBIN_DIR / "kresd" diff --git a/python/knot_resolver/constants.py.in b/python/knot_resolver/constants.py.in index 35c25ac64..8c2974a58 100644 --- a/python/knot_resolver/constants.py.in +++ b/python/knot_resolver/constants.py.in @@ -5,15 +5,18 @@ VERSION = "@version@" USER = "@user@" GROUP = "@group@" -# dirs paths +# default files names +API_SOCK_NAME = "kres-api.sock" + +# default dirs paths RUN_DIR = Path("@run_dir@") ETC_DIR = Path("@etc_dir@") SBIN_DIR = Path("@sbin_dir@") CACHE_DIR = Path("@cache_dir@") -# files paths +# default files paths CONFIG_FILE = ETC_DIR / "config.yaml" -API_SOCK_FILE = RUN_DIR / "kres-api.sock" +API_SOCK_FILE = RUN_DIR / API_SOCK_NAME # executables paths KRESD_EXECUTABLE = SBIN_DIR / "kresd" -- 2.47.3