* [pve-devel] [PATCH guest-common 1/3] mention prune behavior for the vzdump remove parameter @ 2020-10-19 12:33 Fabian Ebner 2020-10-19 12:33 ` [pve-devel] [PATCH manager 2/3] partially fix #2745: use default for " Fabian Ebner 2020-10-19 12:33 ` [pve-devel] [PATCH manager 3/3] fix #2745: backup GUI: allow users to specify remove=1 Fabian Ebner 0 siblings, 2 replies; 3+ messages in thread From: Fabian Ebner @ 2020-10-19 12:33 UTC (permalink / raw) To: pve-devel Signed-off-by: Fabian Ebner <f.ebner@proxmox.com> --- PVE/VZDump/Common.pm | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/PVE/VZDump/Common.pm b/PVE/VZDump/Common.pm index 63a4689..6ae35e6 100644 --- a/PVE/VZDump/Common.pm +++ b/PVE/VZDump/Common.pm @@ -221,7 +221,8 @@ my $confdesc = { }), remove => { type => 'boolean', - description => "Remove old backup files if there are more than 'maxfiles' backup files.", + description => "Remove old backup files if there are more than 'maxfiles' backup files " . + "or prune according to 'prune-backups'.", optional => 1, default => 1, }, -- 2.20.1 ^ permalink raw reply [flat|nested] 3+ messages in thread
* [pve-devel] [PATCH manager 2/3] partially fix #2745: use default for vzdump remove parameter 2020-10-19 12:33 [pve-devel] [PATCH guest-common 1/3] mention prune behavior for the vzdump remove parameter Fabian Ebner @ 2020-10-19 12:33 ` Fabian Ebner 2020-10-19 12:33 ` [pve-devel] [PATCH manager 3/3] fix #2745: backup GUI: allow users to specify remove=1 Fabian Ebner 1 sibling, 0 replies; 3+ messages in thread From: Fabian Ebner @ 2020-10-19 12:33 UTC (permalink / raw) To: pve-devel The initial default from the $confdesc is 1 anyways, and like this, changing the default in /etc/vzdump.conf to 0 actually works. Signed-off-by: Fabian Ebner <f.ebner@proxmox.com> --- PVE/VZDump.pm | 2 -- 1 file changed, 2 deletions(-) diff --git a/PVE/VZDump.pm b/PVE/VZDump.pm index 542228d6..3ccb8269 100644 --- a/PVE/VZDump.pm +++ b/PVE/VZDump.pm @@ -411,8 +411,6 @@ sub new { my $defaults = read_vzdump_defaults(); - $opts->{remove} = 1 if !defined($opts->{remove}); - foreach my $k (keys %$defaults) { next if $k eq 'exclude-path' || $k eq 'maxfiles'; # dealt with separately if ($k eq 'dumpdir' || $k eq 'storage') { -- 2.20.1 ^ permalink raw reply [flat|nested] 3+ messages in thread
* [pve-devel] [PATCH manager 3/3] fix #2745: backup GUI: allow users to specify remove=1 2020-10-19 12:33 [pve-devel] [PATCH guest-common 1/3] mention prune behavior for the vzdump remove parameter Fabian Ebner 2020-10-19 12:33 ` [pve-devel] [PATCH manager 2/3] partially fix #2745: use default for " Fabian Ebner @ 2020-10-19 12:33 ` Fabian Ebner 1 sibling, 0 replies; 3+ messages in thread From: Fabian Ebner @ 2020-10-19 12:33 UTC (permalink / raw) To: pve-devel A user with Datastore.AllocateSpace, VM.Audit, VM.Backup privileges can already remove backups from the GUI manually, so it shouldn't be a problem if they can set the remove flag when starting a manual vzdump job in the GUI. Signed-off-by: Fabian Ebner <f.ebner@proxmox.com> --- www/manager6/window/Backup.js | 17 ++++++++++++++--- 1 file changed, 14 insertions(+), 3 deletions(-) diff --git a/www/manager6/window/Backup.js b/www/manager6/window/Backup.js index 55f52676..8649c738 100644 --- a/www/manager6/window/Backup.js +++ b/www/manager6/window/Backup.js @@ -67,8 +67,19 @@ Ext.define('PVE.window.Backup', { fieldLabel: gettext('Send email to'), name: 'mailto', emptyText: Proxmox.Utils.noneText - } - ] + }, + { + xtype: 'proxmoxcheckbox', + name: 'remove', + checked: false, + uncheckedValue: 0, + fieldLabel: gettext('Remove'), + autoEl: { + tag: 'div', + 'data-qtip': gettext('Remove/prune older backups afterwards'), + }, + }, + ], }); var form = me.formPanel.getForm(); @@ -82,7 +93,7 @@ Ext.define('PVE.window.Backup', { storage: storage, vmid: me.vmid, mode: values.mode, - remove: 0 + remove: values.remove, }; if ( values.mailto ) { -- 2.20.1 ^ permalink raw reply [flat|nested] 3+ messages in thread
end of thread, other threads:[~2020-10-19 12:33 UTC | newest] Thread overview: 3+ messages (download: mbox.gz / follow: Atom feed) -- links below jump to the message on this page -- 2020-10-19 12:33 [pve-devel] [PATCH guest-common 1/3] mention prune behavior for the vzdump remove parameter Fabian Ebner 2020-10-19 12:33 ` [pve-devel] [PATCH manager 2/3] partially fix #2745: use default for " Fabian Ebner 2020-10-19 12:33 ` [pve-devel] [PATCH manager 3/3] fix #2745: backup GUI: allow users to specify remove=1 Fabian Ebner
This is a public inbox, see mirroring instructions for how to clone and mirror all data and code used for this inbox