Fix sysfs service idempotency
Sysfs is kind of "apply params" service, so status should always return true. Service's resource will prefer the 'status' parameter, then 'statuscmd' method, then look in the process table. Partial-Bug: #1524724 Change-Id: I8a13ac4a227195cfb16be89c8fb0a9a9ec3ba1f0
This commit is contained in:
parent
77a59478b7
commit
d040c126d9
|
@ -7,7 +7,7 @@ class sysfs::service inherits sysfs::params {
|
|||
service { 'sysfsutils' :
|
||||
ensure => 'running',
|
||||
enable => true,
|
||||
hasstatus => false,
|
||||
status => '/bin/true',
|
||||
hasrestart => true,
|
||||
}
|
||||
|
||||
|
|
|
@ -20,7 +20,7 @@ describe 'sysfs::service' do
|
|||
should contain_service('sysfsutils').with(
|
||||
:ensure => 'running',
|
||||
:enable => true,
|
||||
:hasstatus => false,
|
||||
:status => '/bin/true',
|
||||
:hasrestart => true)
|
||||
end
|
||||
end
|
||||
|
|
Loading…
Reference in New Issue