diff --git a/sync/latest-images/main.go b/sync/latest-images/main.go index 4366ca0..80b081b 100644 --- a/sync/latest-images/main.go +++ b/sync/latest-images/main.go @@ -63,7 +63,7 @@ func FindRecentImages(bucketName string, prefix string, version string, imageTyp log.Fatalf("uh oh: %v", err) } - pattern := regexp.MustCompile(`(?PRocky-(?P[0-9]+)-(?P\w+)(?:-(?P\w+))?-(?:[0-9]+)\.(?P[0-9])-(?P[0-9]+)\.(?P[0-9]+)\.(?P\w+)/(?P[0-9]+)/(?P(.+\.(?P(box|qcow2|raw|tar\.xz|vhd)))))$`) + pattern := regexp.MustCompile(`(?PRocky-(?P[0-9]+)-(?P\w+)(?:-(?P\w+))?-(?:[0-9]+)\.(?P[0-9]+)-(?P[0-9]+)\.(?P[0-9]+)\.(?P\w+)/(?P[0-9]+)/(?P(.+\.(?P(box|qcow2|raw|tar\.xz|vhd)))))$`) // Loop through the objects and find the latest one for each file type latestByTypeVariant := map[string]map[string]*Image{} for _, obj := range items {