@@ -94,7 +94,7 @@ public struct Utility {
9494 resource: Flags . Resource ,
9595 registry: Flags . Registry ,
9696 progressUpdate: @escaping ProgressUpdateHandler
97- ) async throws -> ( ContainerConfiguration , Kernel ) {
97+ ) async throws -> ( ContainerConfiguration , Kernel , String ? ) {
9898 var requestedPlatform = Parser . platform ( os: management. os, arch: management. arch)
9999 // Prefer --platform
100100 if let platform = management. platform {
@@ -132,25 +132,6 @@ public struct Utility {
132132
133133 let kernel = try await self . getKernel ( management: management)
134134
135- // Pull and unpack the initial filesystem
136- await progressUpdate ( [
137- . setDescription( " Fetching init image " ) ,
138- . setItemsName( " blobs " ) ,
139- ] )
140- let fetchInitTask = await taskManager. startTask ( )
141- let initImage = try await ClientImage . fetch (
142- reference: ClientImage . initImageRef, platform: . current, scheme: scheme,
143- progressUpdate: ProgressTaskCoordinator . handler ( for: fetchInitTask, from: progressUpdate) )
144-
145- await progressUpdate ( [
146- . setDescription( " Unpacking init image " ) ,
147- . setItemsName( " entries " ) ,
148- ] )
149- let unpackInitTask = await taskManager. startTask ( )
150- _ = try await initImage. getCreateSnapshot (
151- platform: . current,
152- progressUpdate: ProgressTaskCoordinator . handler ( for: unpackInitTask, from: progressUpdate) )
153-
154135 await taskManager. finish ( )
155136
156137 let imageConfig = try await img. config ( for: requestedPlatform) . config
@@ -248,7 +229,7 @@ public struct Utility {
248229
249230 config. ssh = management. ssh
250231
251- return ( config, kernel)
232+ return ( config, kernel, management . initImage )
252233 }
253234
254235 static func getAttachmentConfigurations( containerId: String , networks: [ Parser . ParsedNetwork ] ) throws -> [ AttachmentConfiguration ] {
0 commit comments