[pve-devel] [PATCH qemu-server 1/2] api: return UPID in template call

Fabian Grünbichler f.gruenbichler at proxmox.com
Fri Sep 10 12:03:40 CEST 2021


On September 10, 2021 10:32 am, Fabian Ebner wrote:
> The same issues are present for the corresponding API call in 
> pve-container ;)

thanks, should have checked there myself. will send a patch for that as 
well.

> Both patches
> Reviewed-by: Fabian Ebner <f.ebner at proxmox.com>
> 
> Am 10.09.21 um 09:48 schrieb Fabian Grünbichler:
>> as reported on the forum, this is currently missing, making status
>> queries via the API impossible:
>> 
>> https://forum.proxmox.com/threads/create-vm-via-api-interface.95942/#post-416084
>> 
>> Signed-off-by: Fabian Grünbichler <f.gruenbichler at proxmox.com>
>> ---
>>   PVE/API2/Qemu.pm | 8 +++++---
>>   1 file changed, 5 insertions(+), 3 deletions(-)
>> 
>> diff --git a/PVE/API2/Qemu.pm b/PVE/API2/Qemu.pm
>> index ef0d877..0a23525 100644
>> --- a/PVE/API2/Qemu.pm
>> +++ b/PVE/API2/Qemu.pm
>> @@ -4336,7 +4336,10 @@ __PACKAGE__->register_method({
>>   
>>   	},
>>       },
>> -    returns => { type => 'null'},
>> +    returns => {
>> +	type => 'string',
>> +	description => "the task ID.",
>> +    },
>>       code => sub {
>>   	my ($param) = @_;
>>   
>> @@ -4375,8 +4378,7 @@ __PACKAGE__->register_method({
>>   	    return $rpcenv->fork_worker('qmtemplate', $vmid, $authuser, $realcmd);
>>   	};
>>   
>> -	PVE::QemuConfig->lock_config($vmid, $updatefn);
>> -	return;
>> +	return PVE::QemuConfig->lock_config($vmid, $updatefn);
>>       }});
>>   
>>   __PACKAGE__->register_method({
>> 
> 





More information about the pve-devel mailing list