@@ -17,6 +17,8 @@ Base.@kwdef struct BatchImage
17
17
image:: String
18
18
_cpu_image_key:: Union{String, Nothing}
19
19
_gpu_image_key:: Union{String, Nothing}
20
+ _image_tag:: Union{String, Nothing}
21
+ _image_sha:: Union{String, Nothing}
20
22
_is_product_default:: Bool
21
23
_interactive_product_name:: Union{String, Nothing}
22
24
end
@@ -34,6 +36,8 @@ function Base.show(io::IO, ::MIME"text/plain", image::BatchImage)
34
36
print (io, ' \n ' , " image: " , image. image)
35
37
isnothing (image. _cpu_image_key) || print (io, " \n CPU image: " , image. _cpu_image_key)
36
38
isnothing (image. _gpu_image_key) || print (io, " \n GPU image: " , image. _gpu_image_key)
39
+ isnothing (image. _image_tag) || print (io, " :$(image. _image_tag) " )
40
+ isnothing (image. _image_sha) || print (io, " :$(image. _image_sha) " )
37
41
if ! isnothing (image. _interactive_product_name)
38
42
print (io, " \n Features:" )
39
43
print (io, " \n - Expose Port: ✓" )
@@ -214,6 +218,8 @@ Base.@kwdef mutable struct _ImageKeys
214
218
isdefault:: Bool = false
215
219
cpu:: Union{String, Nothing} = nothing
216
220
gpu:: Union{String, Nothing} = nothing
221
+ tag:: Union{String, Nothing} = nothing
222
+ sha:: Union{String, Nothing} = nothing
217
223
end
218
224
219
225
function _group_images (images; image_group:: AbstractString )
@@ -231,9 +237,13 @@ function _group_images(images; image_group::AbstractString)
231
237
end
232
238
image_key_name = _get_json (image, " image_key_name" , String)
233
239
display_name = _get_json (image, " display_name" , String)
240
+ tag = _get_json_or (image, " image_tag" , Union{String, Nothing})
241
+ sha = _get_json_or (image, " image_sha" , Union{String, Nothing})
234
242
image_type = _parse_image_group_entry_type (image)
235
243
isnothing (image_type) && continue # invalid image type will return a nothing, which we will ignore
236
- imagekeys = get! (grouped_images, display_name, _ImageKeys (; isdefault= image_type. isdefault))
244
+ imagekeys = get! (
245
+ grouped_images, display_name, _ImageKeys (; isdefault= image_type. isdefault, tag, sha)
246
+ )
237
247
# If this image key set is already problematic, no point in checking further
238
248
imagekeys. error && continue
239
249
# We make sure that there are no conflicts with base- and option- image types
@@ -333,6 +343,8 @@ function _batchimages_62(auth::Authentication)
333
343
_gpu_image_key = imagekey. gpu,
334
344
_is_product_default = imagekey. isdefault,
335
345
_interactive_product_name = interactive_product_name,
346
+ _image_tag = imagekey. tag,
347
+ _image_sha = imagekey. sha,
336
348
)
337
349
end
338
350
end
0 commit comments