From 9dd47bfb20146b193d4484a9cb2102ab3ea5b43a Mon Sep 17 00:00:00 2001 From: Konrad Bucheli Date: Fri, 19 Jan 2024 14:06:25 +0100 Subject: [PATCH] document how to add a dropin file with Hiera --- admin-guide/configuration/services.md | 25 +++++++++++++++++++++++++ 1 file changed, 25 insertions(+) diff --git a/admin-guide/configuration/services.md b/admin-guide/configuration/services.md index 963c0257..d9ec420f 100644 --- a/admin-guide/configuration/services.md +++ b/admin-guide/configuration/services.md @@ -13,6 +13,31 @@ base::services: ``` The key inside is the `systemd` service name without the `.service` suffix. +## Extend/Override Unit File Entries with a Dropin +You can create a dropin file by setting `dropin` to `true` and add the content of the dropin unit file below the `options` key, as in following examples: +``` +base::services: + netdata: + enable: true + dropin: true + options: + Service: + Environment: "FOO=bar" +``` +or if there is more than one value for the same key: +``` +base::services: + netdata: + enable: true + dropin: true + options: + Service: + Environment: + - "FOO=bar" + - "BIZ=buz" +``` + + ## Disabling/Stopping a Service To stop and disable an already running service, disable it in the `base::services` Hiera key with `enable: false`: