[pve-devel] applied: [PATCH qemu-server] drive: volume in-use check: remove unused closure parameter

2021-04-19 Thread Thomas Lamprecht
On 19.04.21 15:39, Fabian Ebner wrote: > and simplify the calling iteration. > > Suggested-by: Thomas Lamprecht > Signed-off-by: Fabian Ebner > --- > PVE/QemuServer/Drive.pm | 6 +++--- > 1 file changed, 3 insertions(+), 3 deletions(-) > > applied, thanks! __

[pve-devel] [PATCH manager] api: network: fix #3385 check for used ports before writing

2021-04-19 Thread Stoiko Ivanov
Currently the check for used ports for bonds and bridges happens while rendering '/etc/network/interfaces.new' in PVE::Inotify (pve-common). However at that stage the new/updated interface is already merged with the old settings, making it impossible to indicate where a NIC is currently used. The

[pve-devel] [PATCH qemu-server] drive: volume in-use check: remove unused closure parameter

2021-04-19 Thread Fabian Ebner
and simplify the calling iteration. Suggested-by: Thomas Lamprecht Signed-off-by: Fabian Ebner --- PVE/QemuServer/Drive.pm | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/PVE/QemuServer/Drive.pm b/PVE/QemuServer/Drive.pm index 9016a43..0d66b2e 100644 --- a/PVE/QemuServ

[pve-devel] [PATCH manager 7/7] ui: remove SafeDestroy window

2021-04-19 Thread Fabian Ebner
which has been moved to proxmox-widget-toolkit. Signed-off-by: Fabian Ebner --- www/manager6/Makefile | 1 - www/manager6/window/SafeDestroy.js | 194 - 2 files changed, 195 deletions(-) delete mode 100644 www/manager6/window/SafeDestroy.js diff --git

[pve-devel] [PATCH manager 4/7] ui: use new SafeDestroyGuest window

2021-04-19 Thread Fabian Ebner
Signed-off-by: Fabian Ebner --- www/manager6/lxc/Config.js | 3 ++- www/manager6/qemu/Config.js | 3 ++- 2 files changed, 4 insertions(+), 2 deletions(-) diff --git a/www/manager6/lxc/Config.js b/www/manager6/lxc/Config.js index 73e34614..f996bad1 100644 --- a/www/manager6/lxc/Config.js +++ b/w

[pve-devel] [PATCH-SERIES widget-toolkit/manager] Add checkbox for removing unreferenced disks on guest removal

2021-04-19 Thread Fabian Ebner
by allowing generic additional items for the SafeDestroy window in widget-toolkit and deriving a SafeDestroyGuest child class from it. Also switch over the other SafeDestroy users in PVE. proxmox-widget-toolkit: Fabian Ebner (2): safe destroy: remove purge checkbox safe destroy: allow speci

[pve-devel] [PATCH manager 6/7] ui: use safe destroy window from proxmox-widget-toolkit

2021-04-19 Thread Fabian Ebner
for the remaining (i.e. non-guests) users. Signed-off-by: Fabian Ebner --- www/manager6/ceph/Pool.js | 3 ++- www/manager6/storage/ImageView.js | 3 ++- 2 files changed, 4 insertions(+), 2 deletions(-) diff --git a/www/manager6/ceph/Pool.js b/www/manager6/ceph/Pool.js index 5dabd4e6..91

[pve-devel] [PATCH manager 5/7] ui: safe destroy guest: add checkbox for removal of unreferenced disks

2021-04-19 Thread Fabian Ebner
Signed-off-by: Fabian Ebner --- Dependency bump for pve-container and qemu-server is needed. Ideally, the dependency bump for qemu-server also includes [0], so people with snapshots don't run into left-over VM state disks. [0]: https://lists.proxmox.com/pipermail/pve-devel/2021-April/047685.html

[pve-devel] [PATCH manager 3/7] ui: add SafeDestroyGuest window

2021-04-19 Thread Fabian Ebner
The purge parameter is always explicitly set, which is different from the existing behavior, but it does not rely on what the default in the backend is. Signed-off-by: Fabian Ebner --- Dependency bump for proxmox-widget-toolkit is needed. www/manager6/Makefile | 1 + www/man

[pve-devel] [PATCH proxmox-widget-toolkit 2/7] safe destroy: allow specifing additional items

2021-04-19 Thread Fabian Ebner
to be used to add more checkboxes for PVE's guest destroy use case. Signed-off-by: Fabian Ebner --- src/window/SafeDestroy.js | 104 -- 1 file changed, 54 insertions(+), 50 deletions(-) diff --git a/src/window/SafeDestroy.js b/src/window/SafeDestroy.js index

[pve-devel] [PATCH proxmox-widget-toolkit 1/7] safe destroy: remove purge checkbox

2021-04-19 Thread Fabian Ebner
To be replaced by generic additional items specified by the user of the window or child class. AFAICS there are no existing users of this widget yet, so this shouldn't break anything. Signed-off-by: Fabian Ebner --- src/window/SafeDestroy.js | 23 +-- 1 file changed, 1 insert

[pve-devel] applied-series: [PATCH-SERIES v2 qemu-server] Cleanup migration code and improve migration disk cleanup

2021-04-19 Thread Thomas Lamprecht
On 29.01.21 16:11, Fabian Ebner wrote: > This series intends to make the migration code more readable by > simplyfing/unifying how we keep track of local volumes and splitting up > sync_disks into multiple subroutines. > > This is done by keeping more information within the hash of local_volumes w

[pve-devel] [PATCH manager 1/4] ui: Utils: use render functions from widget-toolkit

2021-04-19 Thread Dominik Csapak
they live there now, so we can delete them here and use the ones from widget-toolkit instead Signed-off-by: Dominik Csapak --- www/manager6/Utils.js| 58 +--- www/manager6/ceph/OSD.js | 2 +- www/manager6/ceph/Pool.js| 4 +

[pve-devel] [PATCH manager 4/4] ui: panel/StatusView: use from widget-toolkit instead

2021-04-19 Thread Dominik Csapak
Signed-off-by: Dominik Csapak --- www/manager6/Makefile| 1 - www/manager6/node/StatusView.js | 2 +- www/manager6/panel/GuestStatusView.js| 2 +- www/manager6/panel/StatusView.js | 126 --- www/manager6/panel/TemplateStatusView.j

[pve-devel] [PATCH manager 3/4] ui: Utils: use updateColumns from widget-toolkit

2021-04-19 Thread Dominik Csapak
it was moved there Signed-off-by: Dominik Csapak --- www/manager6/Utils.js | 30 -- www/manager6/dc/Summary.js | 4 ++-- www/manager6/node/Summary.js | 4 ++-- www/manager6/panel/GuestSummary.js | 4 ++-- 4 files changed, 6 insertions(+),

[pve-devel] [PATCH widget-toolkit 2/4] bring over some icons from PVE

2021-04-19 Thread Dominik Csapak
we want to reuse them in PBS Signed-off-by: Dominik Csapak --- src/css/ext6-pmx.css| 25 + src/images/Makefile | 8 +++- src/images/icon-cpu.png | Bin 0 -> 205 bytes src/images/icon-cpu.xcf | Bin 0 -> 816 bytes src/images/icon-ram.png | Bin 0 -> 193 bytes

[pve-devel] [PATCH manager 2/4] ui: use some icons from widget-toolkit

2021-04-19 Thread Dominik Csapak
we moved them there Signed-off-by: Dominik Csapak --- www/css/ext6-pve.css | 12 www/images/Makefile | 4 +--- www/images/icon-cpu.png | Bin 205 -> 0 bytes www/images/icon-cpu.xcf | Bin 816 -> 0 bytes ww

[pve-devel] [PATCH widget-toolkit/pve-manager] move some code to widget-toolkit

2021-04-19 Thread Dominik Csapak
manager needs a depends on a bumped widget-toolkit ofc proxmox-widget-toolkit: Dominik Csapak (4): Utils: add several render functions from PVE bring over some icons from PVE Utils: refactor updateColumns from pve-manager panel: add StatusView from PVE src/Makefile| 1 + s

[pve-devel] [PATCH widget-toolkit 4/4] panel: add StatusView from PVE

2021-04-19 Thread Dominik Csapak
with 2 minor fixups: * one lint error * binding of the 'updateValues' function in the event (we want to avoid breaking this when used in a context where a controller exists, in that case using a string will only look in the controller and not in the component itself anymore, so use the func

[pve-devel] [PATCH widget-toolkit 1/4] Utils: add several render functions from PVE

2021-04-19 Thread Dominik Csapak
we need the 'render_cpu_model' and '*_usage' methods in PBS, the rest are the dependencies Signed-off-by: Dominik Csapak --- src/Utils.js | 60 1 file changed, 60 insertions(+) diff --git a/src/Utils.js b/src/Utils.js index 3fd8f91..9d785a8 1

[pve-devel] [PATCH widget-toolkit 3/4] Utils: refactor updateColumns from pve-manager

2021-04-19 Thread Dominik Csapak
we want to reuse this in pbs Signed-off-by: Dominik Csapak --- src/Utils.js | 30 ++ 1 file changed, 30 insertions(+) diff --git a/src/Utils.js b/src/Utils.js index 9d785a8..adff5f4 100644 --- a/src/Utils.js +++ b/src/Utils.js @@ -1060,6 +1060,36 @@ utilities: {

[pve-devel] applied: [PATCH common] fixup: remove double braces

2021-04-19 Thread Thomas Lamprecht
On 19.04.21 10:43, Stefan Reiter wrote: > Signed-off-by: Stefan Reiter > --- > > either this or apply the second patch soon please ;) > https://lists.proxmox.com/pipermail/pve-devel/2021-April/047594.html > > src/PVE/JSONSchema.pm | 1 - > 1 file changed, 1 deletion(-) > > applied, thanks!

[pve-devel] applied: [PATCH v2 pve-access-control] fix #1500: permission path syntax check for access control

2021-04-19 Thread Thomas Lamprecht
On 19.04.21 09:16, Lorenz Stechauner wrote: > Syntax for permission paths is now checked on API calls for > creation or update on permissions. > > Signed-off-by: Lorenz Stechauner > --- > Regex is now hardcoded, > removed get_permission_paths, > check_path does not call normalize_path anymore,

Re: [pve-devel] [PATCH v2 pve-access-control] fix #1500: permission path syntax check for access control

2021-04-19 Thread Dietmar Maurer
FYI, I do it without any regex in rust: https://git.proxmox.com/?p=proxmox-backup.git;a=blob;f=src/config/acl.rs;h=61e507ec42bf5a30f64f56564a1fb107d148fb7b;hb=HEAD#l272 I guess this is faster (at least in rust). > On 04/19/2021 9:16 AM Lorenz Stechauner wrote: > > > Syntax for permission pa

Re: [pve-devel] [PATCH v6 qemu-server 2/5] disk reassign: add API endpoint

2021-04-19 Thread Aaron Lauterer
On 4/15/21 1:52 PM, Fabian Ebner wrote: One nit and one comment inline. Am 02.04.21 um 12:19 schrieb Aaron Lauterer: The goal of this new API endpoint is to provide an easy way to move a disk between VMs as this was only possible with manual intervention until now. Either by renaming the VM d

Re: [pve-devel] [PATCH v6 qemu-server 2/5] disk reassign: add API endpoint

2021-04-19 Thread Aaron Lauterer
On 4/18/21 5:24 PM, Thomas Lamprecht wrote: On 02.04.21 12:19, Aaron Lauterer wrote: The goal of this new API endpoint is to provide an easy way to move a disk between VMs as this was only possible with manual intervention until now. Either by renaming the VM disk or by manually adding the di

[pve-devel] [PATCH qemu-server 2/2] destroy VM: also check if unused volumes are base images

2021-04-19 Thread Fabian Ebner
It's arguably not likely in practice that only an unused volume is still in use as a base image, but do it for completeness sake. Signed-off-by: Fabian Ebner --- PVE/QemuServer.pm | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/PVE/QemuServer.pm b/PVE/QemuServer.pm index 1af2

[pve-devel] [PATCH qemu-server 1/2] destroy VM: always remove (referenced) VM state volumes

2021-04-19 Thread Fabian Ebner
With --destroy-unreferenced-disks 0 they were not removed yet, but no use in keeping them around. Signed-off-by: Fabian Ebner --- PVE/QemuServer.pm | 19 --- 1 file changed, 16 insertions(+), 3 deletions(-) diff --git a/PVE/QemuServer.pm b/PVE/QemuServer.pm index 1a46732..1af2b5

[pve-devel] [PATCH common] fixup: remove double braces

2021-04-19 Thread Stefan Reiter
Signed-off-by: Stefan Reiter --- either this or apply the second patch soon please ;) https://lists.proxmox.com/pipermail/pve-devel/2021-April/047594.html src/PVE/JSONSchema.pm | 1 - 1 file changed, 1 deletion(-) diff --git a/src/PVE/JSONSchema.pm b/src/PVE/JSONSchema.pm index f2ddb50..3febc1

[pve-devel] [PATCH v2 manager] ui: RBDStorage: add field for RBD namespace

2021-04-19 Thread Aaron Lauterer
Makes it possible to configure the RBD namespace via the GUI. RBD namespaces must be configured manually. The most likely use case is when connecting to an external Ceph cluster as this makes it possible to separate client PVE clusters by namespace, not by pool. Signed-off-by: Aaron Lauterer ---

Re: [pve-devel] [PATCH cluster 2/4] add get_remote_info

2021-04-19 Thread Fabian Grünbichler
On April 18, 2021 7:07 pm, Thomas Lamprecht wrote: > On 13.04.21 14:16, Fabian Grünbichler wrote: >> as a unified helper for talking to a remote node. if the requested node >> has an entry in the remote config, the information from that entry is >> used. else, the first locally defined node of the

Re: [pve-devel] [RFC qemu-server++ 0/22] remote migration

2021-04-19 Thread Moula BADJI
It is a good initiative. I just want to add an idea on the migration of vms, with GPUs. I use K8S (K8s Workers with Nvidia GPU) on VMS deployed on PVE with Maas + Juju. But no possibility to migrate the vm even if the GPUs are identical on two different nodes. Maybe add a constraint with the fa

[pve-devel] [PATCH v2 pve-access-control] fix #1500: permission path syntax check for access control

2021-04-19 Thread Lorenz Stechauner
Syntax for permission paths is now checked on API calls for creation or update on permissions. Signed-off-by: Lorenz Stechauner --- Regex is now hardcoded, removed get_permission_paths, check_path does not call normalize_path anymore, indentation fix PVE/API2/ACL.pm | 4 PVE/Acce