]> git.r.bdr.sh - rbdr/monitorcito/commitdiff
Use description instead of Id
authorRuben Beltran del Rio <redacted>
Mon, 19 Feb 2024 23:54:45 +0000 (23:54 +0000)
committerRuben Beltran del Rio <redacted>
Mon, 19 Feb 2024 23:54:45 +0000 (23:54 +0000)
lib/index.js

index d5d9668985eebd163ad658633b64537a33134996..e8d00192a35758901ced7f0b4a8d01d36b9d085a 100644 (file)
@@ -6,7 +6,7 @@ const internals = {
   kFieldSeparator: '\n',
   kKeyValueSeparator: '=',
   kBlockSeparator: '\n\n',
-  statusCommand: 'systemctl show --no-page -p Id -p ActiveState',
+  statusCommand: 'systemctl show --no-page -p Description -p ActiveState',
 
   formatStatusOutput(systemctlText) {
 
@@ -29,7 +29,7 @@ const internals = {
 
         return {
           ...statusObject,
-          [service.Id]: service.ActiveState === internals.kActiveIndicator
+          [service.Description]: service.ActiveState === internals.kActiveIndicator
         }
       }, {});
   },