@@ -206,7 +206,7 @@ func PullImageSet(
206206
207207 pullCount , totalCount := 1 , len (imageSet )
208208 for imageReferenceString := range imageSet {
209- imageRepo , _ := splitImageRefByRepoAndTag (imageReferenceString )
209+ imageRepo , originalTag := splitImageRefByRepoAndTag (imageReferenceString )
210210
211211 // If we already know the digest of the tagged image, we should pull it by this digest instead of pulling by tag
212212 // to avoid race-conditions between mirroring and releasing new builds on release channels.
@@ -224,6 +224,8 @@ func PullImageSet(
224224
225225 logger .Debugf ("reference here: %s" , ref .String ())
226226
227+ // tag here can be ussually tag or digest
228+ // thats why we need original tag calculated upper
227229 imagePath , tag := splitImageRefByRepoAndTag (pullReference )
228230
229231 scopedClient := client
@@ -256,7 +258,8 @@ func PullImageSet(
256258 layout .WithPlatform (v1.Platform {Architecture : "amd64" , OS : "linux" }),
257259 layout .WithAnnotations (map [string ]string {
258260 "org.opencontainers.image.ref.name" : imageReferenceString ,
259- "io.deckhouse.image.short_tag" : tag ,
261+ // original tag here to have tagged releases as an alias
262+ "io.deckhouse.image.short_tag" : originalTag ,
260263 }),
261264 )
262265 if err != nil {
0 commit comments