mirror of
https://github.com/inspec/inspec
synced 2024-11-27 15:10:44 +00:00
Fix systemd service enabled check
This commit is contained in:
parent
efc85d89ee
commit
f25ab3a373
2 changed files with 2 additions and 2 deletions
|
@ -142,7 +142,7 @@ class Systemd < ServiceManager
|
|||
params['SubState'] == 'running' ? (running = true) : (running = false)
|
||||
# test via systemctl --quiet is-enabled
|
||||
# ActiveState values eg.g inactive, active
|
||||
params['ActiveState'] == 'active' ? (enabled = true) : (enabled = false)
|
||||
params['UnitFileState'] == 'enabled' ? (enabled = true) : (enabled = false)
|
||||
|
||||
{
|
||||
name: params['Id'],
|
||||
|
|
|
@ -2,5 +2,5 @@ Id=sshd.service
|
|||
Names=sshd.service
|
||||
Description=OpenSSH server daemon
|
||||
LoadState=loaded
|
||||
ActiveState=active
|
||||
UnitFileState=enabled
|
||||
SubState=running
|
||||
|
|
Loading…
Reference in a new issue