aboutsummaryrefslogtreecommitdiff
path: root/src/zenutil/service.cpp
diff options
context:
space:
mode:
authorLiam Mitchell <[email protected]>2025-07-25 20:58:17 +0000
committerLiam Mitchell <[email protected]>2025-07-25 20:58:17 +0000
commitbaa420dbc358cb48d26e0aa94a36196f737b3f04 (patch)
treebc2f7c70c18e9ecc7b0186fdb797bf85ab755bef /src/zenutil/service.cpp
parentIncrease service stop timeout to 30 seconds during full install (diff)
downloadzen-baa420dbc358cb48d26e0aa94a36196f737b3f04.tar.xz
zen-baa420dbc358cb48d26e0aa94a36196f737b3f04.zip
Fix permissions and ownership issues with service binary copy and remove unnecessary alias from unit file
Diffstat (limited to 'src/zenutil/service.cpp')
-rw-r--r--src/zenutil/service.cpp7
1 files changed, 2 insertions, 5 deletions
diff --git a/src/zenutil/service.cpp b/src/zenutil/service.cpp
index 6e68a01fa..25941bde1 100644
--- a/src/zenutil/service.cpp
+++ b/src/zenutil/service.cpp
@@ -321,7 +321,6 @@ namespace {
std::string BuildUnitFile(std::string_view ServiceName,
const std::filesystem::path& ExecutablePath,
std::string_view CommandLineOptions,
- std::string_view AliasName,
std::string_view UserName)
{
return fmt::format(
@@ -341,14 +340,12 @@ namespace {
"ExecStart={} {}\n"
"RuntimeDirectory={}\n"
"[Install]\n"
- "Alias={}\n"
"WantedBy=multi-user.target",
ServiceName,
UserName,
ExecutablePath,
CommandLineOptions,
- ExecutablePath.parent_path(),
- AliasName);
+ ExecutablePath.parent_path());
}
#endif // ZEN_PLATFORM_LINUX
@@ -917,7 +914,7 @@ InstallService(std::string_view ServiceName, const ServiceSpec& Spec)
UserName = UserResult.second;
}
- std::string UnitFile = BuildUnitFile(ServiceName, Spec.ExecutablePath, Spec.CommandLineOptions, UnitName, UserName);
+ std::string UnitFile = BuildUnitFile(ServiceName, Spec.ExecutablePath, Spec.CommandLineOptions, UserName);
ZEN_DEBUG("Writing systemd unit file to {}", ServiceUnitPath.string());
try
{