update to 0.1.34

This commit is contained in:
Mickael BOURNEUF 2024-12-17 10:36:54 +01:00
parent fe00221ff8
commit 2e804ee9ca
3 changed files with 20 additions and 16 deletions

View File

@ -40,6 +40,9 @@ class StorageBlockAttached(BaseModel):
id:UUID4 = Field()
order:int = Field()
class StorageBlockDeattached(BaseModel):
id:UUID4 = Field()
"""class DiskDriver(configDom.DevicesDiskDriver):
name:str = Field(default="qemu")
type:configDom.DevicesDiskDriver.typeEnum = Field(default=configDom.DevicesDiskDriver.typeEnum.raw)

View File

@ -162,20 +162,7 @@ class VM(BaseModel):
# Devices
devices:Devices = Field(default=Devices(), description="Matériel virtuel: Périphériques")
"""VM LIST GET"""
class VMs(BaseModel):
model_config = ConfigDict(from_attributes=True)
class Datacenter(BaseModel):
model_config = ConfigDict(from_attributes=True)
id:UUID4
name:str
id:UUID4
name:str
state:int
datacenter:Optional[Datacenter] = Field(default=[])
"""VM GET"""
class VMGetVCPU(VCPU):
@ -212,6 +199,21 @@ class VMGet(VM):
os:VMGetOS = Field(default=VMGetOS(), description="Options VM: Options de démarrage.")
devices:VMGetDevices = Field(default=VMGetDevices(), description="Matériel virtuel: Périphériques")
"""VM LIST GET"""
class VMs(BaseModel):
model_config = ConfigDict(from_attributes=True)
class Datacenter(BaseModel):
model_config = ConfigDict(from_attributes=True)
id:UUID4
name:str
id:UUID4
name:str
state:VMGet.StateEnum = Field(default=None)
datacenter:Optional[Datacenter] = Field(default=[])
"""VM POST"""
class VMPost(VM):
id:UUID4 = Field(default_factory=uuid4)
@ -219,8 +221,7 @@ class VMPost(VM):
"""VM DELETE"""
class VMDelete(BaseModel):
id:UUID4 = Field()
inventory_only:Optional[bool] = Field(default=True)
all_delete:Optional[bool] = Field(default=False)
"""VM STOP"""
class VMStop(BaseModel):

View File

@ -2,7 +2,7 @@ from setuptools import find_packages, setup
setup(
name='deevirt_schema',
version='0.1.33',
version='0.1.34',
description='Deevirt Schema',
url='https://git.celeonet.fr/Deevirt/deevirt_schema.git',
author='Celeonet',