From 00cbd30abf40e4db138379f2b0b757138fcd0ab9 Mon Sep 17 00:00:00 2001 From: Roman Gorshunov Date: Wed, 3 Jul 2019 19:11:15 +0200 Subject: [PATCH] Enhance skip list This patch enhances skip list, so that images matching skip pattern are skipped. Previous behavior was to skip only images ending with pattern. Change-Id: Ic6548048412b6ab4e62398c66fedb888489bd605 --- tools/updater.py | 10 ++++++---- 1 file changed, 6 insertions(+), 4 deletions(-) diff --git a/tools/updater.py b/tools/updater.py index d11dac0f5..ea94e2c37 100755 --- a/tools/updater.py +++ b/tools/updater.py @@ -348,9 +348,9 @@ def traverse(obj, dict_path=None): hash_v = v.split(":") image, old_image_tag = hash_v - if skip_list and image.endswith(skip_list): - LOG.info("Ignoring image %s, " - "it is in a skip list", image) + if skip_list and image in skip_list: + LOG.info("Ignoring image %s, it is in a " + "skip list", image) continue new_image_tag = get_image_tag(image) @@ -509,7 +509,9 @@ if __name__ == "__main__": "\"versions.yaml\" (overwrite existing)") parser.add_argument("--skip", help="comma-delimited list of images and charts " - "to skip during the update") + "to skip during the update; e.g. \"ceph\" " + "will skip all charts and images which have " + "\"ceph\" in the name") parser.add_argument('--tag-filter', help="e.g. \"ubuntu\"; update would use image ref. " "tags on quay.io matching the filter")