Background
There are a few different components involved in a Starnix-powered user experience:
- The
containercomponent, which is the component that is run bystarnix_runner. This component describes the type of Linux environment that Starnix is meant to execute, including which system image to use and whichinitprogram to run. - The
starnix_runnerreceives the run request forcontainerfrom the component framework, and instantiates a newstarnix_kernel. - The
starnix_kernelis the component that executes all the Linux code described by thecontainer.
Picking a component
In order to decide which component is the best target for your capability, consider the following:
Is the capability used in core Starnix functionality?
If the capability is used in the core of Starnix, in a way where you would need to route the capability to virtually every container, then it's often best to route the capability to the
starnix_kerneldirectly.Is it used by a module, or code that is hidden behind a container feature?
In this case, it's best to route the capability to the container. This minimizes the amount of capabilities available to all containers.
A final consideration is in regards to the power of the specific capability.
In order to route a capability to the container it often needs to be
routed through the session. Routing a capability directly to the
starnix_kernel keeps it contained within the platform.