rendu optional cdron sur schema pydantic
This commit is contained in:
parent
b491e69fde
commit
6c935061a9
|
@ -90,7 +90,7 @@ class DevicesInterface(BaseModel):
|
||||||
|
|
||||||
switch_id:UUID4
|
switch_id:UUID4
|
||||||
id:UUID4 = Field(default_factory=uuid4)
|
id:UUID4 = Field(default_factory=uuid4)
|
||||||
mac_addr:str = Field(default=None)
|
mac_addr:str = Field(default='')
|
||||||
|
|
||||||
class Graphics(BaseModel):
|
class Graphics(BaseModel):
|
||||||
port:int = Field(default=-1)
|
port:int = Field(default=-1)
|
||||||
|
@ -121,7 +121,7 @@ class TPM(BaseModel):
|
||||||
|
|
||||||
class Devices(BaseModel):
|
class Devices(BaseModel):
|
||||||
disks:Optional[List[DevicesDisk]] = Field(default=None, description="Disques virtuel")
|
disks:Optional[List[DevicesDisk]] = Field(default=None, description="Disques virtuel")
|
||||||
cdrom:DevicesCDROM = Field(default=None, description="CDROM virtuel")
|
cdrom:Optional[DevicesCDROM] = Field(default=None, description="CDROM virtuel")
|
||||||
interfaces:Optional[List[DevicesInterface]] = Field(default=None, description="Interfaces réseau")
|
interfaces:Optional[List[DevicesInterface]] = Field(default=None, description="Interfaces réseau")
|
||||||
graphics:Optional[Graphics] = Field(default=None, description="Console VNC")
|
graphics:Optional[Graphics] = Field(default=None, description="Console VNC")
|
||||||
audio:Audio = Field(default=None, description="Carte Audio")
|
audio:Audio = Field(default=None, description="Carte Audio")
|
||||||
|
|
Loading…
Reference in New Issue