mirror of
https://github.com/Icinga/icinga-powershell-framework.git
synced 2025-12-21 07:10:15 -05:00
Fixes broken service check due to content validation
This commit is contained in:
parent
cd591f6f43
commit
73b761a4dc
1 changed files with 2 additions and 2 deletions
|
|
@ -59,11 +59,11 @@ function Invoke-IcingaCheckService()
|
|||
|
||||
$FoundService = Get-IcingaServices -Service $Service;
|
||||
$ServiceName = Get-IcingaServiceCheckName -ServiceInput $Service -Service $FoundService;
|
||||
$Status = ConvertTo-ServiceStatusCode -Status $Status;
|
||||
$IntStatus = ConvertTo-ServiceStatusCode -Status $Status;
|
||||
$StatusRaw = $FoundService.Values.configuration.Status.raw;
|
||||
|
||||
$IcingaCheck = New-IcingaCheck -Name $ServiceName -Value $StatusRaw -ObjectExists $FoundService -Translation $ProviderEnums.ServiceStatusName;
|
||||
$IcingaCheck.CritIfNotMatch($Status) | Out-Null;
|
||||
$IcingaCheck.CritIfNotMatch($IntStatus) | Out-Null;
|
||||
$ServicesPackage.AddCheck($IcingaCheck);
|
||||
|
||||
}
|
||||
|
|
|
|||
Loading…
Reference in a new issue