summaryrefslogtreecommitdiff
path: root/CMakeLists.txt
diff options
context:
space:
mode:
authorEmmanuel Gil Peyrot <linkmauve@linkmauve.fr>2016-06-11 01:34:03 +0100
committerEmmanuel Gil Peyrot <linkmauve@linkmauve.fr>2016-06-11 01:34:03 +0100
commitad15924ac3f0852214fd35d93482fc18dbbe4bec (patch)
tree2f29c181a3095b4851f7aa12a7a558471030af1b /CMakeLists.txt
parent272c0e4995f2fe94fb2366c15453fdada341861a (diff)
downloadbiboumi-ad15924ac3f0852214fd35d93482fc18dbbe4bec.tar.gz
biboumi-ad15924ac3f0852214fd35d93482fc18dbbe4bec.tar.bz2
biboumi-ad15924ac3f0852214fd35d93482fc18dbbe4bec.tar.xz
biboumi-ad15924ac3f0852214fd35d93482fc18dbbe4bec.zip
Allow cmake to configure the systemd unit’s user and group
Diffstat (limited to 'CMakeLists.txt')
-rw-r--r--CMakeLists.txt6
1 files changed, 6 insertions, 0 deletions
diff --git a/CMakeLists.txt b/CMakeLists.txt
index bb13460..4559201 100644
--- a/CMakeLists.txt
+++ b/CMakeLists.txt
@@ -267,6 +267,12 @@ else()
set(SYSTEMD_SERVICE_TYPE "simple")
set(WATCHDOG_SEC "")
endif()
+if(NOT DEFINED SERVICE_USER)
+ set(SERVICE_USER "nobody")
+endif()
+if(NOT DEFINED SERVICE_GROUP)
+ set(SERVICE_GROUP "nobody")
+endif()
configure_file(unit/biboumi.service.cmake biboumi.service)
# The date MUST be in english format