virtcontainers: Make fc.go fit the new API

Make fc.go fit the new API

Signed-off-by: Sebastien Boeuf <sebastien.boeuf@intel.com>
This commit is contained in:
Sebastien Boeuf 2019-09-03 19:38:12 -07:00 committed by Julio Montes
parent 67ce7283bc
commit 2a8af23de6

View File

@ -742,13 +742,15 @@ func (fc *firecracker) fcAddVsock(vs kataVSOCK) error {
vsockParams := ops.NewPutGuestVsockByIDParams()
vsockID := "root"
ctxID := int64(vs.contextID)
udsPath := ""
vsock := &models.Vsock{
GuestCid: &ctxID,
ID: &vsockID,
UdsPath: &udsPath,
VsockID: &vsockID,
}
vsockParams.SetID(vsockID)
vsockParams.SetBody(vsock)
_, _, err := fc.client().Operations.PutGuestVsockByID(vsockParams)
_, err := fc.client().Operations.PutGuestVsockByID(vsockParams)
if err != nil {
return err
}