Skip to content

Commit

Permalink
Remove addVsocksHandler from loadSnapshotHandlerList
Browse files Browse the repository at this point in the history
According to the firecracker OpenAPI specification [1], creating vsock
devices is only a pre-boot request, so adding vsocks after loading a
snapshot fails. It also seems redundant, since the VM loaded from a
snapshot restores vsocks anyways.

Closes firecracker-microvm#506

1. https://github.com/firecracker-microvm/firecracker/blob/56aeeac51c00b449a45be4542b3e807d34690ba7/src/api_server/swagger/firecracker.yaml#L676-L678

Signed-off-by: Georgiy Lebedev <lebedev.gk@phystech.edu>
  • Loading branch information
CuriousGeorgiy authored and ustiugov committed Sep 10, 2023
1 parent 4299558 commit 887ea63
Showing 1 changed file with 4 additions and 1 deletion.
5 changes: 4 additions & 1 deletion handlers.go
Original file line number Diff line number Diff line change
Expand Up @@ -321,7 +321,10 @@ var loadSnapshotHandlerList = HandlerList{}.Append(
CreateLogFilesHandler,
BootstrapLoggingHandler,
LoadSnapshotHandler,
AddVsocksHandler,
// According to the firecracker OpenAPI specification, creating vsock devices is only a pre-boot request, so adding
// vsocks after loading a snapshot fails. It also seems redundant, since the VM loaded from a snapshot restores
// vsocks anyways (firecracker-microvm/firecracker-go-sdk#506).
// AddVsocksHandler,
)

var defaultValidationHandlerList = HandlerList{}.Append(
Expand Down

0 comments on commit 887ea63

Please sign in to comment.