[pve-devel] [PATCH] pve-storage autocompletion

2015-09-30 Thread Alen Grizonic
--- PVE/API2/Storage/Config.pm | 4 ++- PVE/API2/Storage/Content.pm | 43 ++- PVE/API2/Storage/Status.pm | 29 ++--- PVE/CLI/pvesm.pm| 3 +++ PVE/Storage.pm | 62 + 5 files

[pve-devel] [PATCH] pvesm list fix

2015-09-28 Thread Alen Grizonic
--- PVE/API2/Storage/Content.pm | 13 ++--- 1 file changed, 10 insertions(+), 3 deletions(-) diff --git a/PVE/API2/Storage/Content.pm b/PVE/API2/Storage/Content.pm index a7e9fe3..63dc0a4 100644 --- a/PVE/API2/Storage/Content.pm +++ b/PVE/API2/Storage/Content.pm @@ -67,6 +67,8 @@

[pve-devel] [PATCH v2] CT protection mode

2015-09-22 Thread Alen Grizonic
[PATCH 2] changes: - added common check_protection subroutine - disk removal or update operation - restore over protected CT prevention - changed man page message --- src/PVE/API2/LXC.pm | 6 -- src/PVE/LXC.pm | 15 --- 2 files changed, 16 insertions(+), 5 deletions(-)

[pve-devel] [PATCH pve-container] CT protection mode

2015-09-22 Thread Alen Grizonic
changes: - added common check_protection subroutine - disk removal prevention - restore over protected CT prevention --- src/PVE/API2/LXC.pm| 6 -- src/PVE/API2/LXC/Config.pm | 4 src/PVE/LXC.pm | 8 3 files changed, 16 insertions(+), 2 deletions(-) diff

[pve-devel] [PATCH] check_vmid_unused message change

2015-09-22 Thread Alen Grizonic
changed message if vmid used on a different cluster node --- data/PVE/Cluster.pm | 13 ++--- 1 file changed, 10 insertions(+), 3 deletions(-) diff --git a/data/PVE/Cluster.pm b/data/PVE/Cluster.pm index 63780ac..880d91a 100644 --- a/data/PVE/Cluster.pm +++ b/data/PVE/Cluster.pm @@

[pve-devel] [PATCH v2 qemu-server 2/2] VM protection mode

2015-09-18 Thread Alen Grizonic
[PATCH v2] changes: - changed call also for remove VM --- PVE/API2/Qemu.pm | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/PVE/API2/Qemu.pm b/PVE/API2/Qemu.pm index 8eea6e9..780a8fb 100644 --- a/PVE/API2/Qemu.pm +++ b/PVE/API2/Qemu.pm @@ -1163,8 +1163,7 @@

[pve-devel] [PATCH qemu-server] VM protection mode

2015-09-17 Thread Alen Grizonic
changes: - added common check_protection subroutine - disk removal prevention - restore over protected VM prevention - changed man page message --- PVE/API2/Qemu.pm | 33 ++--- 1 file changed, 26 insertions(+), 7 deletions(-) diff --git a/PVE/API2/Qemu.pm

Re: [pve-devel] [RFC v6 qemu-server] VM protection mode

2015-09-11 Thread Alen Grizonic
On 09/10/2015 06:44 PM, Dietmar Maurer wrote: @@ -889,6 +897,7 @@ my $update_vm_api = sub { $modified->{$opt} = 1; $conf = PVE::QemuServer::load_config($vmid); # update/reload if ($opt =~ m/^unused/) { +

[pve-devel] [RFC vb3 pve-container] CT protection mode

2015-09-10 Thread Alen Grizonic
v2 changes: - protection mode removal prevention - disk removal prevention --- src/PVE/LXC.pm | 12 ++-- 1 file changed, 10 insertions(+), 2 deletions(-) diff --git a/src/PVE/LXC.pm b/src/PVE/LXC.pm index ebf5d23..7679670 100644 --- a/src/PVE/LXC.pm +++ b/src/PVE/LXC.pm @@ -179,7

[pve-devel] [RFC vb2 pve-container] CT protection mode

2015-09-10 Thread Alen Grizonic
v2 changes: - protection mode removal prevention - disk removal prevention --- src/PVE/LXC.pm | 9 +++-- 1 file changed, 7 insertions(+), 2 deletions(-) diff --git a/src/PVE/LXC.pm b/src/PVE/LXC.pm index ebf5d23..4cb7809 100644 --- a/src/PVE/LXC.pm +++ b/src/PVE/LXC.pm @@ -179,7 +179,7 @@

[pve-devel] [RFC v4 qemu-server] VM protection mode

2015-09-10 Thread Alen Grizonic
v4 changes: - disk removal prevention - protection option removal prevention - changed man page message --- PVE/API2/Qemu.pm | 5 + PVE/QemuServer.pm | 2 +- 2 files changed, 6 insertions(+), 1 deletion(-) diff --git a/PVE/API2/Qemu.pm b/PVE/API2/Qemu.pm index fabd490..3df14e8 100644 ---

Re: [pve-devel] [RFC v5 qemu-server] VM protection mode

2015-09-10 Thread Alen Grizonic
The thing is that the checks are always repeated, but the error messages are different. I can still add a new common subroutine. Now it actually make sense. On 09/10/2015 05:24 PM, Alen Grizonic wrote: Agree. I also like non duplicated code, so I'll fix it and add an additional restriction

[pve-devel] [RFC v5 qemu-server] VM protection mode

2015-09-10 Thread Alen Grizonic
v5 changes: - disk removal prevention -> added unused disk removal prevention - protection option removal prevention - changed man page message --- PVE/API2/Qemu.pm | 8 PVE/QemuServer.pm | 2 +- 2 files changed, 9 insertions(+), 1 deletion(-) diff --git a/PVE/API2/Qemu.pm

Re: [pve-devel] [RFC v5 qemu-server] VM protection mode

2015-09-10 Thread Alen Grizonic
Agree. I also like non duplicated code, so I'll fix it and add an additional restriction right away. Thanks. On 09/10/2015 05:19 PM, Dietmar Maurer wrote: The code is still clumsy - to show what I mean I just left the '+' lines and removed everything else. +if

Re: [pve-devel] [RFC v5 qemu-server] VM protection mode

2015-09-10 Thread Alen Grizonic
Dietmar, sorry for the delayed reply. Yes, we can use just if ($conf->{protection}) { ... On 09/10/2015 04:59 PM, Dietmar Maurer wrote: +if (($conf->{protection}) && ($conf->{protection} == 1)) { What is the purpose of this strict test? I thought the following is good

[pve-devel] [RFC v6 qemu-server] VM protection mode

2015-09-10 Thread Alen Grizonic
v6 changes: - disk removal prevention -> added unused disk removal prevention - protection option removal prevention - changed man page message - added common check_protection subroutine --- PVE/API2/Qemu.pm | 15 +-- PVE/QemuServer.pm | 2 +- 2 files changed, 14 insertions(+), 3

Re: [pve-devel] [RFC v6 qemu-server] VM protection mode

2015-09-10 Thread Alen Grizonic
This should do the trick ;-) On 09/10/2015 06:30 PM, Alen Grizonic wrote: v6 changes: - disk removal prevention -> added unused disk removal prevention - protection option removal prevention - changed man page message - added common check_protection subroutine --- PVE/API2/Qemu.pm |

[pve-devel] [RFC v3 pve-container] CT protection mode added

2015-09-04 Thread Alen Grizonic
v3 changes: - disk removal prevention - preventing restore over existing CT - changed error and man messages --- src/PVE/API2/LXC.pm| 9 - src/PVE/API2/LXC/Config.pm | 10 +- src/PVE/LXC.pm | 10 ++ 3 files changed, 27 insertions(+), 2 deletions(-)

Re: [pve-devel] [PATCH] fix bug #701: blacklist nvidiafb

2015-09-04 Thread Alen Grizonic
Anyway, I would suggest to change the error messages to: On 09/04/2015 09:57 AM, Alen Grizonic wrote: On 09/04/2015 09:42 AM, Alen Grizonic wrote: On 09/04/2015 09:27 AM, Wolfgang Link wrote: --- proxmox-ve/postinst | 6 ++ 1 file changed, 6 insertions(+) diff --git a/proxmox-ve

Re: [pve-devel] [PATCH] fix bug #701: blacklist nvidiafb

2015-09-04 Thread Alen Grizonic
On 09/04/2015 09:42 AM, Alen Grizonic wrote: On 09/04/2015 09:27 AM, Wolfgang Link wrote: --- proxmox-ve/postinst | 6 ++ 1 file changed, 6 insertions(+) diff --git a/proxmox-ve/postinst b/proxmox-ve/postinst index be375d2..74dca77 100755 --- a/proxmox-ve/postinst +++ b/proxmox-ve

[pve-devel] [RFC pve-container] CT protection mode added

2015-09-03 Thread Alen Grizonic
--- src/PVE/API2/LXC.pm | 3 +++ src/PVE/LXC.pm | 10 ++ 2 files changed, 13 insertions(+) diff --git a/src/PVE/API2/LXC.pm b/src/PVE/API2/LXC.pm index d5acace..fbc2eda 100644 --- a/src/PVE/API2/LXC.pm +++ b/src/PVE/API2/LXC.pm @@ -535,6 +535,9 @@ __PACKAGE__->register_method({

[pve-devel] [RFC pve-manager v2] GUI option for VM protection added

2015-09-03 Thread Alen Grizonic
v2 changes: GUI option for CT protection added --- www/manager/lxc/Options.js | 17 + www/manager/qemu/Options.js | 17 + 2 files changed, 34 insertions(+) diff --git a/www/manager/lxc/Options.js b/www/manager/lxc/Options.js index 998602d..8461514 100644 ---

[pve-devel] [RFC qemu-server] VM protection mode added

2015-09-03 Thread Alen Grizonic
used to forbid a virtual machine remove operation --- PVE/API2/Qemu.pm | 11 +++ PVE/QemuServer.pm | 6 ++ 2 files changed, 17 insertions(+) diff --git a/PVE/API2/Qemu.pm b/PVE/API2/Qemu.pm index 20d73f7..5fc0397 100644 --- a/PVE/API2/Qemu.pm +++ b/PVE/API2/Qemu.pm @@ -299,6

[pve-devel] [RFC pve-manager] GUI option for VM protection added

2015-09-03 Thread Alen Grizonic
--- www/manager/qemu/Options.js | 17 + 1 file changed, 17 insertions(+) diff --git a/www/manager/qemu/Options.js b/www/manager/qemu/Options.js index 0d3e210..f5d0f80 100644 --- a/www/manager/qemu/Options.js +++ b/www/manager/qemu/Options.js @@ -237,6 +237,23 @@

[pve-devel] protection mode added

2015-09-03 Thread Alen Grizonic
added the option to forbid a VM removal -> with VM protection (mode) enabled -> adding also the LXC part as soon as possible ___ pve-devel mailing list pve-devel@pve.proxmox.com http://pve.proxmox.com/cgi-bin/mailman/listinfo/pve-devel

[pve-devel] [RFC v3 qemu-server] VM protection mode added

2015-09-03 Thread Alen Grizonic
used to prevent an unintended virtual machine remove operation v3 changes: - changed man page message - removed protection parameter (where not needed) --- PVE/API2/Qemu.pm | 3 +++ PVE/QemuServer.pm | 6 ++ 2 files changed, 9 insertions(+) diff --git a/PVE/API2/Qemu.pm b/PVE/API2/Qemu.pm

Re: [pve-devel] [RFC v2 qemu-server] VM protection mode added

2015-09-03 Thread Alen Grizonic
You are right. I was just checking again if it is used inside any method and I don't find any reference, so I will remove it. Thanks! On 09/03/2015 02:54 PM, Thomas Lamprecht wrote: Why does the protection parameter gets extracted here when it's never used anywhere inside this method?

[pve-devel] [RFC v2 qemu-server] VM protection mode added

2015-09-03 Thread Alen Grizonic
used to forbid a virtual machine remove operation v2 changes: error message --- PVE/API2/Qemu.pm | 11 +++ PVE/QemuServer.pm | 6 ++ 2 files changed, 17 insertions(+) diff --git a/PVE/API2/Qemu.pm b/PVE/API2/Qemu.pm index 20d73f7..a302d06 100644 --- a/PVE/API2/Qemu.pm +++

[pve-devel] [PATCH v3] HA parse_sid changed to accept CT

2015-09-01 Thread Alen Grizonic
[PATCH v3] changes: - fixed VM/CT exist check - added internal error exception --- src/PVE/HA/Tools.pm | 22 ++ 1 file changed, 18 insertions(+), 4 deletions(-) diff --git a/src/PVE/HA/Tools.pm b/src/PVE/HA/Tools.pm index 94613de..f3f6110 100644 --- a/src/PVE/HA/Tools.pm +++

[pve-devel] [PATCH v4] HA parse_sid changed to accept CT

2015-09-01 Thread Alen Grizonic
[PATCH v4] changes: - fixed VM/CT exist check - added internal error exception - changed/fixed description message --- src/PVE/HA/Tools.pm | 22 ++ 1 file changed, 18 insertions(+), 4 deletions(-) diff --git a/src/PVE/HA/Tools.pm b/src/PVE/HA/Tools.pm index 94613de..896b7ab

[pve-devel] [PATCH v2] HA parse_sid changed to accept CT

2015-09-01 Thread Alen Grizonic
[PATCH v2] changes -> VM/CT exist check added --- src/PVE/HA/Config.pm | 1 + src/PVE/HA/Tools.pm | 20 2 files changed, 17 insertions(+), 4 deletions(-) diff --git a/src/PVE/HA/Config.pm b/src/PVE/HA/Config.pm index 58f5b58..b860abc 100644 --- a/src/PVE/HA/Config.pm +++

[pve-devel] [PATCH] HA parse_sid changed to accept CT

2015-08-31 Thread Alen Grizonic
--- src/PVE/HA/Tools.pm | 15 +++ 1 file changed, 11 insertions(+), 4 deletions(-) diff --git a/src/PVE/HA/Tools.pm b/src/PVE/HA/Tools.pm index 94613de..2b9ca6c 100644 --- a/src/PVE/HA/Tools.pm +++ b/src/PVE/HA/Tools.pm @@ -5,6 +5,7 @@ use warnings; use JSON; use PVE::JSONSchema;

[pve-devel] [PATCH] lxc detect error message changed

2015-08-31 Thread Alen Grizonic
--- src/PVE/API2/LXC.pm | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/PVE/API2/LXC.pm b/src/PVE/API2/LXC.pm index 2c42622..7411bdd 100644 --- a/src/PVE/API2/LXC.pm +++ b/src/PVE/API2/LXC.pm @@ -311,7 +311,7 @@ __PACKAGE__->register_method({ my

[pve-devel] [PATCH] HA resources check before destroying vm

2015-08-28 Thread Alen Grizonic
--- PVE/API2/Qemu.pm | 4 1 file changed, 4 insertions(+) diff --git a/PVE/API2/Qemu.pm b/PVE/API2/Qemu.pm index 513b224..a6ad831 100644 --- a/PVE/API2/Qemu.pm +++ b/PVE/API2/Qemu.pm @@ -1142,6 +1142,10 @@ __PACKAGE__-register_method({ my $storecfg = PVE::Storage::config(); +

[pve-devel] [PATCH] HA resources check before destroying lxc

2015-08-28 Thread Alen Grizonic
--- src/PVE/API2/LXC.pm | 4 1 file changed, 4 insertions(+) diff --git a/src/PVE/API2/LXC.pm b/src/PVE/API2/LXC.pm index 35f2c24..303f0ce 100644 --- a/src/PVE/API2/LXC.pm +++ b/src/PVE/API2/LXC.pm @@ -532,6 +532,10 @@ __PACKAGE__-register_method({ my $storage_cfg =

[pve-devel] [PATCH v2] HA resources check before destroying lxc

2015-08-28 Thread Alen Grizonic
[PATCH v2] error message changed --- src/PVE/API2/LXC.pm | 3 +++ 1 file changed, 3 insertions(+) diff --git a/src/PVE/API2/LXC.pm b/src/PVE/API2/LXC.pm index 35f2c24..935493b 100644 --- a/src/PVE/API2/LXC.pm +++ b/src/PVE/API2/LXC.pm @@ -532,6 +532,9 @@ __PACKAGE__-register_method({

[pve-devel] [PATCH v2] HA resources check before destroying vm

2015-08-28 Thread Alen Grizonic
[PATCH v2] error message changed --- PVE/API2/Qemu.pm | 3 +++ 1 file changed, 3 insertions(+) diff --git a/PVE/API2/Qemu.pm b/PVE/API2/Qemu.pm index 513b224..73a1572 100644 --- a/PVE/API2/Qemu.pm +++ b/PVE/API2/Qemu.pm @@ -1142,6 +1142,9 @@ __PACKAGE__-register_method({ my $storecfg =

Re: [pve-devel] [PATCH] HA resources check before destroying lxc

2015-08-28 Thread Alen Grizonic
The code in PVE::HA::Config::vm_is_ha_managed assumes that the LXC insertion in the HA resources file /etc/pve/ha/resources.cfg starts with vm: so if we decide to change the insert to ct:, some code has to be added! On 08/28/2015 03:03 PM, Alen Grizonic wrote: --- src/PVE/API2/LXC.pm | 4

[pve-devel] [PATCH v2 2/2] HA resources check before destroying lxc

2015-08-28 Thread Alen Grizonic
[PATCH v2] error message changed --- src/PVE/API2/LXC.pm | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) diff --git a/src/PVE/API2/LXC.pm b/src/PVE/API2/LXC.pm index 303f0ce..935493b 100644 --- a/src/PVE/API2/LXC.pm +++ b/src/PVE/API2/LXC.pm @@ -532,9 +532,8 @@

[pve-devel] [PATCH v2 2/2] HA resources check before destroying vm

2015-08-28 Thread Alen Grizonic
[PATCH v2] error message changed --- PVE/API2/Qemu.pm | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/PVE/API2/Qemu.pm b/PVE/API2/Qemu.pm index a6ad831..73a1572 100644 --- a/PVE/API2/Qemu.pm +++ b/PVE/API2/Qemu.pm @@ -1143,8 +1143,7 @@ __PACKAGE__-register_method({

Re: [pve-devel] firewall remove config file

2015-08-26 Thread Alen Grizonic
Hi Stefan. The remove function was applied to PVE 4. On 08/26/2015 08:58 AM, Stefan Priebe - Profihost AG wrote: Hi, the firewall config isn't removed in PVE 3.4 at VM delete. Not sure if this one is enough:

Re: [pve-devel] firewall remove config file

2015-08-26 Thread Alen Grizonic
Hi Stefan. Since we are adding a lot of new functionality and covering numerous older bugs like this in the new version, we were not planning to backport them in this very moment. On 08/26/2015 09:01 AM, Stefan Priebe - Profihost AG wrote: Am 26.08.2015 um 09:01 schrieb Alen Grizonic: Hi

[pve-devel] [PATCH] subroutine for cloning vm's firewall config file

2015-08-24 Thread Alen Grizonic
--- src/PVE/Firewall.pm | 15 +++ 1 file changed, 15 insertions(+) diff --git a/src/PVE/Firewall.pm b/src/PVE/Firewall.pm index 5962a4f..c1f871d 100644 --- a/src/PVE/Firewall.pm +++ b/src/PVE/Firewall.pm @@ -2827,6 +2827,21 @@ sub remove_vmfw_conf { unlink $vmfw_conffile; }

[pve-devel] [PATCH] clone vm firewall config file

2015-08-21 Thread Alen Grizonic
Signed-off-by: Alen Grizonic a.grizo...@proxmox.com --- PVE/API2/Qemu.pm | 2 ++ 1 file changed, 2 insertions(+) diff --git a/PVE/API2/Qemu.pm b/PVE/API2/Qemu.pm index 0dd413b..db6424e 100644 --- a/PVE/API2/Qemu.pm +++ b/PVE/API2/Qemu.pm @@ -2282,6 +2282,8 @@ __PACKAGE__-register_method

[pve-devel] [PATCH] clone vm firewall config

2015-08-21 Thread Alen Grizonic
clone vm firewall config file when cloning vm Signed-off-by: Alen Grizonic a.grizo...@proxmox.com --- src/PVE/Firewall.pm | 15 +++ 1 file changed, 15 insertions(+) diff --git a/src/PVE/Firewall.pm b/src/PVE/Firewall.pm index 5962a4f..ffe1abe 100644 --- a/src/PVE/Firewall.pm +++ b

[pve-devel] [PATCH 2/2] remove storage access permissions after delete

2015-08-19 Thread Alen Grizonic
--- PVE/API2/Storage/Config.pm | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/PVE/API2/Storage/Config.pm b/PVE/API2/Storage/Config.pm index 4255299..06656ae 100755 --- a/PVE/API2/Storage/Config.pm +++ b/PVE/API2/Storage/Config.pm @@ -254,7 +254,9 @@

[pve-devel] [PATCH 1/2] added remove storage (exist) check

2015-08-19 Thread Alen Grizonic
--- PVE/API2/Storage/Config.pm | 3 +++ 1 file changed, 3 insertions(+) diff --git a/PVE/API2/Storage/Config.pm b/PVE/API2/Storage/Config.pm index 27b3a55..4255299 100755 --- a/PVE/API2/Storage/Config.pm +++ b/PVE/API2/Storage/Config.pm @@ -243,6 +243,9 @@ __PACKAGE__-register_method ({

[pve-devel] [PATCH] Bugfix 603: vmid.fw file not deleted

2015-08-19 Thread Alen Grizonic
Signed-off-by: Alen Grizonic a.grizo...@proxmox.com --- PVE/API2/Qemu.pm | 2 ++ 1 file changed, 2 insertions(+) diff --git a/PVE/API2/Qemu.pm b/PVE/API2/Qemu.pm index 24a066f..28efbc1 100644 --- a/PVE/API2/Qemu.pm +++ b/PVE/API2/Qemu.pm @@ -1148,6 +1148,8 @@ __PACKAGE__-register_method

[pve-devel] [PATCH] remove vmid.fw file after lxc vm destroy

2015-08-19 Thread Alen Grizonic
Related to Bugfix 603: vmid.fw file not deleted Signed-off-by: Alen Grizonic a.grizo...@proxmox.com --- src/PVE/API2/LXC.pm | 2 ++ 1 file changed, 2 insertions(+) diff --git a/src/PVE/API2/LXC.pm b/src/PVE/API2/LXC.pm index 0d373c7..d330e76 100644 --- a/src/PVE/API2/LXC.pm +++ b/src/PVE/API2

[pve-devel] [PATCH] firewall remove config file subroutine added

2015-08-19 Thread Alen Grizonic
Signed-off-by: Alen Grizonic a.grizo...@proxmox.com --- src/PVE/Firewall.pm | 8 1 file changed, 8 insertions(+) diff --git a/src/PVE/Firewall.pm b/src/PVE/Firewall.pm index de66352..5962a4f 100644 --- a/src/PVE/Firewall.pm +++ b/src/PVE/Firewall.pm @@ -2819,6 +2819,14 @@ sub

[pve-devel] [PATCH v2] access permissions cleanup fix

2015-08-13 Thread Alen Grizonic
for removed vms and pools Signed-off-by: Alen Grizonic a.grizo...@proxmox.com --- PVE/AccessControl.pm | 26 ++ 1 file changed, 22 insertions(+), 4 deletions(-) diff --git a/PVE/AccessControl.pm b/PVE/AccessControl.pm index bfee816..54577aa 100644 --- a/PVE

Re: [pve-devel] [PATCH] remove vm permissions after vm destroy

2015-08-12 Thread Alen Grizonic
ok. let me think about it. On 08/12/2015 04:41 PM, Dietmar Maurer wrote: I just wonder if we can avoid multiple locks/writes on user.cfg file, by adding an additional function which does both things at once? @@ -1204,6 +1193,8 @@ __PACKAGE__-register_method({

[pve-devel] [PATCH] added permission cleanup subroutine for removed vm

2015-08-12 Thread Alen Grizonic
Signed-off-by: Alen Grizonic a.grizo...@proxmox.com --- PVE/AccessControl.pm | 14 ++ 1 file changed, 14 insertions(+) diff --git a/PVE/AccessControl.pm b/PVE/AccessControl.pm index bfee816..807380b 100644 --- a/PVE/AccessControl.pm +++ b/PVE/AccessControl.pm @@ -1096,6 +1096,20

[pve-devel] [PATCH] remove vm permissions after vm destroy

2015-08-12 Thread Alen Grizonic
also removed duplicated code which is used in PVE::AccessControl and not in PVE::API2::Qemu Signed-off-by: Alen Grizonic a.grizo...@proxmox.com --- PVE/API2/Qemu.pm | 13 ++--- 1 file changed, 2 insertions(+), 11 deletions(-) diff --git a/PVE/API2/Qemu.pm b/PVE/API2/Qemu.pm index

[pve-devel] [PATCH] firewall iptables_get_chains device name fix

2015-08-11 Thread Alen Grizonic
Signed-off-by: Alen Grizonic a.grizo...@proxmox.com --- src/PVE/Firewall.pm | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/PVE/Firewall.pm b/src/PVE/Firewall.pm index 1e918ab..b1fb978 100644 --- a/src/PVE/Firewall.pm +++ b/src/PVE/Firewall.pm @@ -1524,7 +1524,7 @@ sub

[pve-devel] [PATCH 2/2] removed firewall code for openVZ

2015-08-11 Thread Alen Grizonic
and verify_rule changed to check for an LXC veth-type interface device name --- src/PVE/Firewall.pm | 137 ++-- 1 file changed, 5 insertions(+), 132 deletions(-) diff --git a/src/PVE/Firewall.pm b/src/PVE/Firewall.pm index 1e918ab..83bab55 100644

[pve-devel] [PATCH] removed firewall code for openVZ

2015-08-11 Thread Alen Grizonic
[PATCH 2/2] changed to [PATCH] with the following fix: Subroutine verify_rule (re)fixed to correctly check only for eth (on vm) or veth (on ct) interface device names --- src/PVE/Firewall.pm | 137 ++-- 1 file changed, 5 insertions(+), 132

[pve-devel] [PATCH 2/2] verify_rule pattern change for lxc

2015-08-11 Thread Alen Grizonic
Subroutine verify_rule now accepts only values matching netX or ethX interface device name patterns when adding firewall rules for linux containers. --- src/PVE/Firewall.pm | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/PVE/Firewall.pm b/src/PVE/Firewall.pm index

[pve-devel] [PATCH v2 2/2] bug #659 (pool support) fix

2015-07-28 Thread Alen Grizonic
lxc added to additional GUI pool functions (also for ExtJS5) Signed-off-by: Alen Grizonic a.grizo...@proxmox.com --- www/manager/form/ViewSelector.js | 4 ++-- www/manager/grid/PoolMembers.js | 4 ++-- www/manager5/form/ViewSelector.js | 4 ++-- www/manager5/grid/PoolMembers.js | 4 ++-- www

[pve-devel] [PATCH] lxc added to pool register method

2015-07-14 Thread Alen Grizonic
Signed-off-by: Alen Grizonic a.grizo...@proxmox.com --- PVE/API2/Pool.pm | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/PVE/API2/Pool.pm b/PVE/API2/Pool.pm index 68ed337..567c7e8 100644 --- a/PVE/API2/Pool.pm +++ b/PVE/API2/Pool.pm @@ -222,7 +222,7 @@ __PACKAGE__

[pve-devel] [PATCH] validate error message (typo) corrected

2015-07-14 Thread Alen Grizonic
Signed-off-by: Alen Grizonic a.grizo...@proxmox.com --- src/PVE/RESTHandler.pm | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/PVE/RESTHandler.pm b/src/PVE/RESTHandler.pm index ad0f929..ae0a695 100644 --- a/src/PVE/RESTHandler.pm +++ b/src/PVE/RESTHandler.pm @@ -395,7

[pve-devel] [PATCH] firewall - Ceph macro added

2015-07-14 Thread Alen Grizonic
Signed-off-by: Alen Grizonic a.grizo...@proxmox.com --- src/PVE/Firewall.pm | 5 + 1 file changed, 5 insertions(+) diff --git a/src/PVE/Firewall.pm b/src/PVE/Firewall.pm index ed46db1..26fc63e 100644 --- a/src/PVE/Firewall.pm +++ b/src/PVE/Firewall.pm @@ -166,6 +166,11 @@ my $pve_fw_macros

Re: [pve-devel] [PATCH v3 2/2] firewall autodisable GUI patch

2015-07-01 Thread Alen Grizonic
Yes, in this case we can simply use a fixed method. Thanks. On 07/01/2015 02:13 PM, Dietmar Maurer wrote: + PVE.Utils.API2Request({ + url: me.url, + waitMsgTarget: me, + method: me.method || (me.backgroundDelay ? 'POST' : 'PUT'), Can we

[pve-devel] [PATCH v3 2/2] firewall autodisable GUI patch

2015-07-01 Thread Alen Grizonic
conditions - the patch needs the keepalive feature disabled to work correctly Changes since [PATCH] v2: - removed some more unused code - changed the digest handling by removing it on the second API call ( this version still uses the disabled keepalive feature ) Signed-off-by: Alen Grizonic a.grizo

Re: [pve-devel] [PATCH] firewall autodisable GUI update

2015-06-30 Thread Alen Grizonic
Yes, I agree. Some part of the code has to be let out. Other comments inline: On 06/29/2015 07:21 PM, Dietmar Maurer wrote: comments inline var rows = {}; +var submit_twice = function(enable) { + + var me = this; + +var form = me.formPanel.getForm();

[pve-devel] [PATCH 2/2] firewall autodisable GUI patch v2

2015-06-30 Thread Alen Grizonic
flag change conditions ! the patch needs the keepalive feature disabled to work correctly ! Signed-off-by: Alen Grizonic a.grizo...@proxmox.com --- www/manager/grid/FirewallOptions.js | 60 - 1 file changed, 59 insertions(+), 1 deletion(-) diff --git a/www

Re: [pve-devel] [PATCH 2/2] firewall autodisable GUI patch v2

2015-06-30 Thread Alen Grizonic
I pointed out the keepalive feature as a non-permanent one. Signed-off-by: Alen Grizonic a.grizo...@proxmox.com --- www/manager/grid/FirewallOptions.js | 60 - 1 file changed, 59 insertions(+), 1 deletion(-) diff --git a/www/manager/grid

[pve-devel] [PATCH] firewall autodisable GUI update

2015-06-29 Thread Alen Grizonic
Signed-off-by: Alen Grizonic a.grizo...@proxmox.com --- www/manager/grid/FirewallOptions.js | 80 - www/manager/window/Edit.js | 2 + 2 files changed, 80 insertions(+), 2 deletions(-) diff --git a/www/manager/grid/FirewallOptions.js b/www/manager

[pve-devel] [PATCH 3/3] firewall instant API call update

2015-06-25 Thread Alen Grizonic
Signed-off-by: Alen Grizonic a.grizo...@proxmox.com --- src/PVE/API2/Firewall/Cluster.pm | 6 +- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/src/PVE/API2/Firewall/Cluster.pm b/src/PVE/API2/Firewall/Cluster.pm index ea51fcc..c4e2b63 100644 --- a/src/PVE/API2/Firewall

[pve-devel] [PATCH] firewall autodisable

2015-06-25 Thread Alen Grizonic
firewall enable parameter type changed from boolean to integer so it can store the timestamp of the firewall enable call to avoid an admin remote lockout Signed-off-by: Alen Grizonic a.grizo...@proxmox.com --- src/PVE/API2/Firewall/Cluster.pm | 7 --- src/PVE/Firewall.pm | 8

[pve-devel] [PATCH 2/2] firewall instant API call apply

2015-06-25 Thread Alen Grizonic
--- src/PVE/API2/Firewall/Cluster.pm | 2 ++ 1 file changed, 2 insertions(+) diff --git a/src/PVE/API2/Firewall/Cluster.pm b/src/PVE/API2/Firewall/Cluster.pm index b924f4e..ea51fcc 100644 --- a/src/PVE/API2/Firewall/Cluster.pm +++ b/src/PVE/API2/Firewall/Cluster.pm @@ -175,6 +175,8 @@

[pve-devel] [PATCH] firewall_module_duplicate

2015-06-24 Thread Alen Grizonic
removed duplicated line of Data::Dumper use Signed-off-by: Alen Grizonic a.grizo...@proxmox.com --- src/PVE/Firewall.pm | 2 -- 1 file changed, 2 deletions(-) diff --git a/src/PVE/Firewall.pm b/src/PVE/Firewall.pm index f0c105e..0049403 100644 --- a/src/PVE/Firewall.pm +++ b/src/PVE/Firewall.pm

Re: [pve-devel] Preview of the GUI with ExtJS5

2015-06-23 Thread Alen Grizonic
I think the ext-theme-gray theme does look quite ok. Also concerning the logo. Dietmar, what do you think? On 06/23/2015 08:19 AM, Daniel Hunsaker wrote: Might be good to take the opportunity to build a new, Proxmox-specific ExtJS5 theme... Something that goes well with the logo, for

[pve-devel] [PATCH] pvecm use of uninitialized value $ARGV[0]

2015-06-18 Thread Alen Grizonic
Just a small bug fix for the pvecm script which did not verify the argument existence during the $ARGV[0] check (when argument not used). Script run error - Use of uninitialized value $ARGV[0] in string ne at /usr/bin/pvecm line 26. Signed-off-by: Alen Grizonic a.grizo...@proxmox.com --- data

[pve-devel] [PATCH] pveceph script double declaration

2015-06-18 Thread Alen Grizonic
Found a double variable declaration that needs to be removed. diff --git a/bin/pveceph b/bin/pveceph index a7467d9..227eaa1 100755 --- a/bin/pveceph +++ b/bin/pveceph @@ -24,7 +24,6 @@ use PVE::CLIHandler; use base qw(PVE::CLIHandler); -my $cmddef; my $nodename = PVE::INotify::nodename();

Re: [pve-devel] [PATCH] PVE:Daemon start/restart with systemd

2015-06-17 Thread Alen Grizonic
Couldn't agree more, so here is the polished version with systemctl added also to stop the service. diff --git a/src/PVE/Daemon.pm b/src/PVE/Daemon.pm index e051500..fb9a923 100644 --- a/src/PVE/Daemon.pm +++ b/src/PVE/Daemon.pm @@ -578,6 +578,16 @@ my $read_pid = sub { return $pid; };

[pve-devel] [PATCH] PVE:Daemon start/restart with systemd

2015-06-16 Thread Alen Grizonic
Added some lines which make it possible to start/restart daemons with pve scripts, avoiding the problem of systemd not recognizing the new status of the (re)started services. diff --git a/src/PVE/Daemon.pm b/src/PVE/Daemon.pm index e051500..16e08c9 100644 --- a/src/PVE/Daemon.pm @@ -578,6