From 704cb9eba76f4134f534ae1935dfea4e5d86aec0 Mon Sep 17 00:00:00 2001 From: Ben Kochie Date: Thu, 5 Nov 2020 06:58:36 +0100 Subject: [PATCH] Fix OPTS arguments Remove `{}` from OPTS env in ExecStart, causes argument to be sent as a single quote string, rather than expansion of arguments. Prefix EnvironmentFile with `-` to make it optional. Signed-off-by: Ben Kochie --- packaging/process-exporter.service | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/packaging/process-exporter.service b/packaging/process-exporter.service index 9d5f6f5..772b1d8 100644 --- a/packaging/process-exporter.service +++ b/packaging/process-exporter.service @@ -4,8 +4,8 @@ Description=Process Exporter for Prometheus [Service] User=root Type=simple -EnvironmentFile=/etc/default/process-exporter -ExecStart=/usr/bin/process-exporter ${OPTS} +EnvironmentFile=-/etc/default/process-exporter +ExecStart=/usr/bin/process-exporter $OPTS KillMode=process Restart=always