osbuild: introduce device host service
A new host service that provides device functionality to stages. Since stages run in a container and are restricted from creating device nodes, all device handling is done in the main osbuild process. Currently this is done with the help of APIs and RPC, e.g. `LoopServer`. Device host services on the other hand allow declaring devices in the manifest itself and then osbuild will prepare all devices before running the stage. One desired effect is that it makes device handling transparent to the stages, e.g. they don't have to know about loopback devices, LVM or LUKS. Another result is that specific device handling is now modular like Inputs and Source are and thus moved out of osbuild itself.
This commit is contained in:
parent
26b15a062d
commit
4f211eb0a5
5 changed files with 165 additions and 0 deletions
|
|
@ -16,6 +16,26 @@
|
|||
|
||||
"definitions": {
|
||||
|
||||
"devices": {
|
||||
"title": "Collection of devices for a stage",
|
||||
"additionalProperties": {
|
||||
"$ref": "#/definitions/device"
|
||||
}
|
||||
},
|
||||
|
||||
"device": {
|
||||
"title": "Device for a stage",
|
||||
"additionalProperties": false,
|
||||
"required": ["type", "options"],
|
||||
"properties": {
|
||||
"type": { "type": "string" },
|
||||
"options": {
|
||||
"type": "object",
|
||||
"additionalProperties": true
|
||||
}
|
||||
}
|
||||
},
|
||||
|
||||
"inputs": {
|
||||
"title": "Collection of inputs for a stage",
|
||||
"additionalProperties": false,
|
||||
|
|
@ -102,6 +122,7 @@
|
|||
"additionalProperties": false,
|
||||
"properties": {
|
||||
"type": { "type": "string" },
|
||||
"devices": { "$ref": "#/definitions/devices" },
|
||||
"inputs": {"$ref": "#/definitions/inputs" },
|
||||
"options": {
|
||||
"type": "object",
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue