mirror of
https://github.com/argoproj/argo-cd
synced 2026-04-21 17:07:16 +00:00
19 lines
540 B
Lua
19 lines
540 B
Lua
local hs = {}
|
|
if obj.status ~= nil and obj.status.conditions ~= nil then
|
|
for i, condition in ipairs(obj.status.conditions) do
|
|
if condition.type == "Ready" then
|
|
if condition.status == "False" then
|
|
hs.status = "Degraded"
|
|
hs.message = condition.message
|
|
return hs
|
|
elseif condition.status == "True" then
|
|
hs.status = "Healthy"
|
|
hs.message = condition.message
|
|
return hs
|
|
end
|
|
end
|
|
end
|
|
end
|
|
hs.status = "Progressing"
|
|
hs.message = "Waiting for NodePool to be ready"
|
|
return hs
|