@@ -34,10 +34,16 @@ struct CacheInputs {
3434 /// This is crucial because it determines the upgrade source for the installed system
3535 source_imgref : String ,
3636
37+ /// Target transport
38+ #[ serde( skip_serializing_if = "Option::is_none" ) ]
39+ target_transport : Option < String > ,
40+
3741 /// Filesystem type used for installation (e.g., "ext4", "xfs", "btrfs")
42+ #[ serde( skip_serializing_if = "Option::is_none" ) ]
3843 filesystem : Option < String > ,
3944
4045 /// Root filesystem size if specified
46+ #[ serde( skip_serializing_if = "Option::is_none" ) ]
4147 root_size : Option < String > ,
4248
4349 /// Whether to use composefs-native storage
@@ -60,6 +66,9 @@ pub struct DiskImageMetadata {
6066 /// This is crucial because it determines the upgrade source for the installed system
6167 pub source_imgref : String ,
6268
69+ /// Target transport
70+ pub target_transport : Option < String > ,
71+
6372 /// Filesystem type used for installation (e.g., "ext4", "xfs", "btrfs")
6473 pub filesystem : Option < String > ,
6574
@@ -82,6 +91,7 @@ impl DiskImageMetadata {
8291 let inputs = CacheInputs {
8392 image_digest : self . digest . clone ( ) ,
8493 source_imgref : self . source_imgref . clone ( ) ,
94+ target_transport : self . target_transport . clone ( ) ,
8595 filesystem : self . filesystem . clone ( ) ,
8696 root_size : self . root_size . clone ( ) ,
8797 composefs_backend : self . composefs_backend ,
@@ -169,6 +179,7 @@ impl DiskImageMetadata {
169179 version : 1 ,
170180 digest : image_digest. to_owned ( ) ,
171181 source_imgref : source_imgref. to_owned ( ) ,
182+ target_transport : options. target_transport . clone ( ) ,
172183 filesystem : options. filesystem . clone ( ) ,
173184 root_size : options. root_size . clone ( ) ,
174185 kernel_args : options. karg . clone ( ) ,
@@ -326,6 +337,7 @@ mod tests {
326337 let inputs = CacheInputs {
327338 image_digest : "sha256:abc123" . to_string ( ) ,
328339 source_imgref : "quay.io/test/image:v1" . to_string ( ) ,
340+ target_transport : None ,
329341 filesystem : Some ( "ext4" . to_string ( ) ) ,
330342 root_size : Some ( "20G" . to_string ( ) ) ,
331343 kernel_args : vec ! [ "console=ttyS0" . to_string( ) ] ,
0 commit comments