summaryrefslogtreecommitdiff
path: root/CMakeLists.txt
diff options
context:
space:
mode:
authorDimitri Staessens <dimitri@ouroboros.rocks>2023-10-07 19:14:59 +0200
committerSander Vrijders <sander@ouroboros.rocks>2023-10-25 09:53:27 +0200
commit669108f477f404b58364bec8a49712f25d05bfe2 (patch)
treeae9c7eff1f08e96398f554780c73df9e5a94fdc2 /CMakeLists.txt
parent5706bf3efa8d8262982bbed15fb041e536f56cf2 (diff)
downloadouroboros-669108f477f404b58364bec8a49712f25d05bfe2.tar.gz
ouroboros-669108f477f404b58364bec8a49712f25d05bfe2.zip
irmd: Don't load config file without --config set
The irmd was automatically loading the default configfile (usually /etc/ouroboros/irmd.conf) if present. Now the --config parameter has to be set for the irmd to load a config. The service is adapted to have the --config command line parameter set at install. Signed-off-by: Dimitri Staessens <dimitri@ouroboros.rocks> Signed-off-by: Sander Vrijders <sander@ouroboros.rocks>
Diffstat (limited to 'CMakeLists.txt')
-rw-r--r--CMakeLists.txt5
1 files changed, 5 insertions, 0 deletions
diff --git a/CMakeLists.txt b/CMakeLists.txt
index 7b030d3f..75645319 100644
--- a/CMakeLists.txt
+++ b/CMakeLists.txt
@@ -135,6 +135,11 @@ if (SYSTEMD_FOUND)
endif ()
if (NOT ${SYSTEMD_UNITDIR} STREQUAL "")
message(STATUS "Installing systemd service in: ${SYSTEMD_UNITDIR}")
+ if (LIBTOML_LIBRARIES AND NOT DISABLE_CONFIGFILE)
+ set (CONFIGURE_STRING "--config ${OUROBOROS_CONFIG_DIR}${OUROBOROS_CONFIG_FILE}")
+ else ()
+ set (CONFIGURE_STRING "")
+ endif ()
configure_file("${CMAKE_CURRENT_SOURCE_DIR}/ouroboros.service.in"
"${CMAKE_CURRENT_BINARY_DIR}/ouroboros.service" @ONLY)
install(FILES "${CMAKE_CURRENT_BINARY_DIR}/ouroboros.service"