feat: add cluster update/delete endpoints, expand tcp/udp protocol handling, and enhance cluster management UI
Add PATCH /clusters/{cluster_id} endpoint with optional token update and audit logging, implement DELETE /clusters/{cluster_id} with cascading deletion of nodes, workloads, networks, subnets, and IP addresses, expand firewall rule generation to split tcp/udp protocol into separate tcp and udp rules for Proxmox compatibility, add ClusterUpdate schema with optional api_token field, include
This commit is contained in:
@@ -71,6 +71,15 @@ class ClusterCreate(BaseModel):
|
||||
verify_tls: bool = True
|
||||
|
||||
|
||||
class ClusterUpdate(BaseModel):
|
||||
name: str
|
||||
api_url: str
|
||||
api_token: str | None = Field(default=None, min_length=8)
|
||||
provider: str = "proxmox"
|
||||
mode: str = "read_only"
|
||||
verify_tls: bool = True
|
||||
|
||||
|
||||
class TenantCreate(BaseModel):
|
||||
name: str
|
||||
description: str | None = None
|
||||
@@ -157,6 +166,7 @@ class ClusterRead(OrmModel):
|
||||
api_url: str
|
||||
provider: str
|
||||
mode: str
|
||||
verify_tls: bool
|
||||
last_sync_at: datetime | None
|
||||
last_sync_status: str | None
|
||||
last_sync_error: str | None
|
||||
|
||||
Reference in New Issue
Block a user