Can view from web UI XML definition of domains

This commit is contained in:
2023-12-08 18:14:01 +01:00
parent 74b77be013
commit 82447a0018
13 changed files with 632 additions and 135 deletions

@ -113,6 +113,10 @@ export class VMInfo implements VMInfoInterface {
get VNCURL(): string {
return `/vm/${this.uuid}/vnc`;
}
get XMLURL(): string {
return `/vm/${this.uuid}/xml`;
}
}
export class VMApi {
@ -154,6 +158,18 @@ export class VMApi {
return new VMInfo(data);
}
/**
* Get the source XML configuration of a domain for debugging purposes
*/
static async GetSingleXML(uuid: string): Promise<string> {
return (
await APIClient.exec({
uri: `/vm/${uuid}/src`,
method: "GET",
})
).data;
}
/**
* Update the information about a single VM
*/