@@ -179,9 +179,8 @@ func (v *Virt) VirtualizationResourceRemap(ctx context.Context, opts *enginetype
179
179
}
180
180
181
181
// VirtualizationCopyTo copies one.
182
- func (v * Virt ) VirtualizationCopyTo (ctx context.Context , ID , target string , content io.Reader , AllowOverwriteDirWithFile , CopyUIDGID bool ) (err error ) {
183
- log .Warnf (ctx , "VirtualizationCopyTo does not implement" )
184
- return
182
+ func (v * Virt ) VirtualizationCopyTo (ctx context.Context , ID , dest string , content io.Reader , AllowOverwriteDirWithFile , CopyUIDGID bool ) error {
183
+ return v .client .CopyToGuest (ctx , ID , dest , content , AllowOverwriteDirWithFile , CopyUIDGID )
185
184
}
186
185
187
186
// VirtualizationStart boots a guest.
@@ -209,7 +208,7 @@ func (v *Virt) VirtualizationInspect(ctx context.Context, ID string) (*enginetyp
209
208
return nil , err
210
209
}
211
210
212
- bytes , err := json .Marshal (coretypes.LabelMeta {Publish : []string {"PORT" }})
211
+ content , err := json .Marshal (coretypes.LabelMeta {Publish : []string {"PORT" }})
213
212
if err != nil {
214
213
return nil , err
215
214
}
@@ -219,7 +218,7 @@ func (v *Virt) VirtualizationInspect(ctx context.Context, ID string) (*enginetyp
219
218
Image : guest .ImageName ,
220
219
Running : guest .Status == "running" ,
221
220
Networks : guest .Networks ,
222
- Labels : map [string ]string {cluster .LabelMeta : string (bytes ), cluster .ERUMark : "1" },
221
+ Labels : map [string ]string {cluster .LabelMeta : string (content ), cluster .ERUMark : "1" },
223
222
}, nil
224
223
}
225
224
@@ -277,6 +276,6 @@ func (v *Virt) VirtualizationExecute(ctx context.Context, ID string, commands, e
277
276
278
277
// ResourceValidate validate resource usage
279
278
func (v * Virt ) ResourceValidate (ctx context.Context , cpu float64 , cpumap map [string ]int64 , memory , storage int64 ) error {
280
- // TODO list all workloads, calcuate resource
279
+ // TODO list all workloads, calculate resource
281
280
return nil
282
281
}
0 commit comments