Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[patch] Extend custom Application healthcheck to detect Helm chart rendering failures #1201

Merged
merged 1 commit into from
Aug 23, 2024
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
15 changes: 15 additions & 0 deletions image/cli/mascli/templates/gitops/bootstrap/argocd.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -1055,6 +1055,21 @@ spec:
hs.status = "Progressing"
hs.message = ""
if obj.status ~= nil then

if obj.status.conditions ~= nil then
for i, condition in ipairs(obj.status.conditions) do
if condition.type == "ComparisonError" and condition.status ~= "False" then
hs.status = "Degraded"
if condition.message ~= nil then
hs.message = condition.message
else
hs.message = "ComparisonError"
end
return hs
end
end
end

if obj.status.health ~= nil then
hs.status = obj.status.health.status
if obj.status.health.message ~= nil then
Expand Down