SHA256
1
0
forked from pool/telegraf
telegraf/harden_telegraf.service.patch
2024-01-10 05:04:11 +00:00

25 lines
702 B
Diff

diff --git a/scripts/telegraf.service b/scripts/telegraf.service
index 94cd26a5..c741bd59 100644
--- a/scripts/telegraf.service
+++ b/scripts/telegraf.service
@@ -5,6 +5,19 @@ After=network-online.target
Wants=network-online.target
[Service]
+# added automatically, for details please see
+# https://en.opensuse.org/openSUSE:Security_Features#Systemd_hardening_effort
+ProtectSystem=full
+ProtectHome=true
+PrivateDevices=true
+ProtectHostname=true
+ProtectClock=true
+ProtectKernelTunables=true
+ProtectKernelModules=true
+ProtectKernelLogs=true
+ProtectControlGroups=true
+RestrictRealtime=true
+# end of automatic additions
Type=notify
NotifyAccess=all
EnvironmentFile=-/etc/default/telegraf