summaryrefslogtreecommitdiff
path: root/pkg
diff options
context:
space:
mode:
authorjannfis <jann@mistrust.net>2022-01-12 13:45:56 +0100
committerGitHub <noreply@github.com>2022-01-12 13:45:56 +0100
commitc5889a2c77300129de4fefd5572c817f3fd5f4b5 (patch)
tree6faa6f7827f1832117e77178072466bd16cf0289 /pkg
parent02aa138b150f56f6f9167c0529570b6044fc1021 (diff)
feat: Improve visibility for skipped apps (#344)
Signed-off-by: jannfis <jann@mistrust.net>
Diffstat (limited to 'pkg')
-rw-r--r--pkg/argocd/argocd.go30
1 files changed, 15 insertions, 15 deletions
diff --git a/pkg/argocd/argocd.go b/pkg/argocd/argocd.go
index ba988f9..1ffec04 100644
--- a/pkg/argocd/argocd.go
+++ b/pkg/argocd/argocd.go
@@ -153,31 +153,31 @@ func FilterApplicationsForUpdate(apps []v1alpha1.Application, patterns []string)
for _, app := range apps {
+ // Check whether application has our annotation set
+ annotations := app.GetAnnotations()
+ if _, ok := annotations[common.ImageUpdaterAnnotation]; !ok {
+ log.Tracef("skipping app '%s' of type '%s' because required annotation is missing", app.GetName(), app.Status.SourceType)
+ continue
+ }
+
// Check for valid application type
if !IsValidApplicationType(&app) {
- log.Tracef("skipping app '%s' of type '%s' because it's not of supported source type", app.GetName(), app.Status.SourceType)
+ log.Warnf("skipping app '%s' of type '%s' because it's not of supported source type", app.GetName(), app.Status.SourceType)
continue
}
// Check if application name matches requested patterns
if !nameMatchesPattern(app.GetName(), patterns) {
- log.Tracef("Skipping app '%s' because it does not match requested patterns", app.GetName())
+ log.Debugf("Skipping app '%s' because it does not match requested patterns", app.GetName())
continue
}
- // Check whether application has our annotation set
- annotations := app.GetAnnotations()
- if _, ok := annotations[common.ImageUpdaterAnnotation]; !ok {
- log.Tracef("skipping app '%s' of type '%s' because required annotation is missing", app.GetName(), app.Status.SourceType)
- continue
- } else {
- log.Tracef("processing app '%s' of type '%v'", app.GetName(), app.Status.SourceType)
- imageList := parseImageList(annotations)
- appImages := ApplicationImages{}
- appImages.Application = app
- appImages.Images = *imageList
- appsForUpdate[app.GetName()] = appImages
- }
+ log.Tracef("processing app '%s' of type '%v'", app.GetName(), app.Status.SourceType)
+ imageList := parseImageList(annotations)
+ appImages := ApplicationImages{}
+ appImages.Application = app
+ appImages.Images = *imageList
+ appsForUpdate[app.GetName()] = appImages
}
return appsForUpdate, nil