Replies: 4 comments 21 replies
-
Why do you need built-in drivers?
Could be also No strong opinion though
|
Beta Was this translation helpful? Give feedback.
-
|
I think there is a bit of a naming disconnect between I think I would prefer renaming I prefer
Other ideas? |
Beta Was this translation helpful? Give feedback.
-
|
The three drivers: Qemu, vz and wsl2 are currently present in the |
Beta Was this translation helpful? Give feedback.
-
|
Since we had a Zoom call, and also some discussion on Slack, I want to summarize what we (@AkihiroSuda, @afbjorklund, @unsuman, and @jandubois) have agreed on so far:
|
Beta Was this translation helpful? Give feedback.
Uh oh!
There was an error while loading. Please reload this page.
Uh oh!
There was an error while loading. Please reload this page.
-
Lima Driver Registry and Discovery
These are my thoughts how I expect Lima drivers to work once we have both built-in and external drivers:
There is no extra driver registry configuration file
limactlwill discover installed drivers automatically. External drivers have names likelima-driver-virtualbox. Only the first driver of a specific name is registered. The priority sequence is:limactlPATHdirectoryDriver implementations don't have hard-coded names
Drivers have a default name under which they register, but they are only used when compiled into
limactl. External driver names are derived from the executable name. If you rename the file, the driver name changes as well.built-in drivers are registered via an
initfunctionIf the driver source is included in the compilation, it automatically registers its
NewDriverfunction with its built-in name. If you include an additional driver in the compilation oflimactlthen it will automatically be built-in.external drivers are registered with an RPC wrapper
For external drivers we will register a
NewDriverfunction that is a closure of the name and path, and implements an RPC shim to the external driver.Drivers don't need to know if they are built-in or external
The source code of a driver does not need to be changed to build it internally or externally; it is just controlled by build options. We may use a
--tags driverstag to include all in-tree drivers. Compiling without the tag will result in alimactlthat has no built-in drivers.We will have a single "driver host"
Compiling
cmd/lima-drivertogether with any actual driver implementation will produce an executable for that driver.There is basically a single driver that has self-registered with its default name (inside the driver host). The driver host will update the registration with the driver name derived from the executable name, and then expose the driver via RPC.
The user can get a list of available drivers
limactl create --list-driversshows a list off all driver names.limactl infowill include adriversproperty with both names of all drivers, and paths for external drivers.Beta Was this translation helpful? Give feedback.
All reactions