With working LXC migration function

This commit is contained in:
Malik Recoing 2025-04-17 10:04:33 +02:00
parent 1b0a394ca8
commit 27a1642fbf

View File

@ -1,4 +1,4 @@
openapi: "3.1.0" openapi: 3.1.0
info: info:
title: Proxmox Cluster Extended API title: Proxmox Cluster Extended API
version: "1.2" version: "1.2"
@ -21,7 +21,6 @@ paths:
type: array type: array
items: items:
type: object type: object
/nodes: /nodes:
get: get:
operationId: listNodes operationId: listNodes
@ -49,7 +48,6 @@ paths:
type: integer type: integer
maxmem: maxmem:
type: integer type: integer
/nodes/{node}/status: /nodes/{node}/status:
get: get:
operationId: getNodeStatus operationId: getNodeStatus
@ -70,7 +68,6 @@ paths:
properties: properties:
data: data:
type: object type: object
/cluster/resources: /cluster/resources:
get: get:
operationId: getClusterResources operationId: getClusterResources
@ -87,7 +84,6 @@ paths:
type: array type: array
items: items:
type: object type: object
/cluster/replication: /cluster/replication:
get: get:
operationId: listReplicationJobs operationId: listReplicationJobs
@ -104,45 +100,6 @@ paths:
type: array type: array
items: items:
type: object type: object
/cluster/replication/{id}:
get:
operationId: getReplicationJob
summary: Lit la configuration dun job de réplication
parameters:
- name: id
in: path
required: true
schema:
type: string
responses:
"200":
description: Configuration du job de réplication
content:
application/json:
schema:
type: object
properties:
data:
type: object
delete:
operationId: deleteReplicationJob
summary: Supprime un job de réplication
parameters:
- name: id
in: path
required: true
schema:
type: string
responses:
"200":
description: Job supprimé avec succès
content:
application/json:
schema:
type: object
/nodes/{node}/lxc: /nodes/{node}/lxc:
get: get:
operationId: listLxcContainers operationId: listLxcContainers
@ -165,7 +122,6 @@ paths:
type: array type: array
items: items:
type: object type: object
/nodes/{node}/qemu: /nodes/{node}/qemu:
get: get:
operationId: listQemuVMs operationId: listQemuVMs
@ -188,7 +144,6 @@ paths:
type: array type: array
items: items:
type: object type: object
/cluster/ceph/status: /cluster/ceph/status:
get: get:
operationId: getCephStatus operationId: getCephStatus
@ -202,4 +157,59 @@ paths:
type: object type: object
properties: properties:
data: data:
type: object type: object
/nodes/{node}/lxc/{vmid}/migrate:
post:
operationId: migrateLxcContainer
summary: Migre un conteneur LXC vers un autre noeud
description: Démarre la migration d'un conteneur LXC depuis un noeud source vers un noeud cible. Utilise "1" ou "0" pour
les champs boolean comme online et restart.
parameters:
- name: node
in: path
required: true
schema:
type: string
- name: vmid
in: path
required: true
schema:
type: integer
requestBody:
required: true
content:
application/x-www-form-urlencoded:
schema:
type: object
properties:
target:
type: string
description: Nom du noeud cible
online:
type: string
enum:
- "1"
- "0"
description: 1 pour une migration a chaud, 0 sinon
restart:
type: string
enum:
- "1"
- "0"
description: 1 pour forcer le redemarrage, 0 sinon
timeout:
type: integer
description: Delai d'attente avant expiration (en secondes)
required:
- target
responses:
"200":
description: Migration lancee avec succes
content:
application/json:
schema:
type: object
properties:
data:
type: string
description: Identifiant de la tache (UPID)