Commit Graph

25 Commits

Author SHA1 Message Date
Aaron Lauterer
ac0fe8b66c api: backup: add endpoint to list included guests and volumes
This patch adds a new API endpoint that returns a list of included
guests, their volumes and whether they are included in a backup.

The output is formatted to be used with the extJS tree panel.

Signed-off-by: Aaron Lauterer <a.lauterer@proxmox.com>
2020-07-09 14:12:59 +02:00
Thomas Lamprecht
e6d963ca3e backup: update job: add missing permission description
Signed-off-by: Thomas Lamprecht <t.lamprecht@proxmox.com>
2020-07-08 13:53:57 +02:00
Thomas Lamprecht
2617768f2c backup: factor out param permission check
Signed-off-by: Thomas Lamprecht <t.lamprecht@proxmox.com>
2020-07-08 13:48:21 +02:00
Oguz Bektas
d5b9f2e1cb backup: add missing user check in update_job
Signed-off-by: Oguz Bektas <o.bektas@proxmox.com>
2020-07-08 13:41:38 +02:00
Christian Ebner
2424074ee7 vzdump: move code needed for cfs register of vzdump.cron to guest-common
This moves the cfs register code for vzdump.cron to the
pve-guest-common package. Therefore, it relies on the corresponding
patches in pve-guest-common and pve-docs as build dependencies.

Signed-off-by: Christian Ebner <c.ebner@proxmox.com>
Signed-off-by: Thomas Lamprecht <t.lamprecht@proxmox.com>
2019-10-18 08:23:40 +02:00
Stefan Reiter
b05c990876 Delete "exclude" when switching a backup job to pool mode
If you updated a job in "exclude" mode with some VMIDs specified to "pool" mode,
the backup job would retain the "exclude" section and thus not back up all VMs.

The GUI misrepresents this, showing that all VMs will be backed up or
straight up break and show "exclude" mode again, with the backend still
being on "pool" - to prevent this, we always delete a jobs "exclude" list
when it's switched to "pool".

Co-authored-by: Tim Marx <t.marx@proxmox.com>
Signed-off-by: Stefan Reiter <s.reiter@proxmox.com>
2019-08-16 13:09:42 +02:00
Stefan Reiter
43b2494b79 Code cleanup in Backup
Whitespace removal and consolidating VZDump's job id format into a
local variable.

Signed-off-by: Stefan Reiter <s.reiter@proxmox.com>
2019-08-14 14:02:53 +02:00
Thomas Lamprecht
c92c54d54b api: backup pool: enforce VM.Backup permissions on pool also on create
Signed-off-by: Thomas Lamprecht <t.lamprecht@proxmox.com>
2019-06-28 20:04:04 +02:00
Thomas Lamprecht
16f5b2834e api: backup pool: enforce VM.Backup permissions on pool
Signed-off-by: Thomas Lamprecht <t.lamprecht@proxmox.com>
2019-06-28 19:29:46 +02:00
Tim Marx
f337626155 fix #1278 api: add pool backup option
Signed-off-by: Tim Marx <t.marx@proxmox.com>
2019-06-28 18:05:19 +02:00
Tim Marx
60e049c231 whitespace cleanup
Signed-off-by: Tim Marx <t.marx@proxmox.com>
2019-06-28 18:01:04 +02:00
Christian Ebner
200cef80ee backup jobs: Aquire lock before modifying vzdump.cron
Signed-off-by: Christian Ebner <c.ebner@proxmox.com>
2019-06-25 11:43:31 +02:00
Fabian Grünbichler
f0bbc08419 restrict vzdump cron options
modeled after the VZDump API path, but since we are
restricted to Sys.Modify users already, we only need to
restrict these three options.
2016-10-17 10:36:06 +02:00
Thomas Lamprecht
4341db1d2f Added functionality do disable temporary a backup job
Added an option to disable a backup job while preserving its
settings. When a job is disabled a '#' is added in front of the vzdump
command in the vzdump.cron file. So the cron job still fires,
but only a comment gets executed. If we would comment out the cron job
a bit more changes to the parser would be needed.

Signed-off-by: Thomas Lamprecht <t.lamprecht@proxmox.com>
2015-07-27 09:15:09 +02:00
Dietmar Maurer
94c47be79d fix typo 2015-06-02 08:42:32 +02:00
Tobias Doerffel
f9adc7763d Fixed typo in backup API
Signed-off-by: Tobias Doerffel <tobias.doerffel@ed-chemnitz.de>
2014-11-24 06:36:48 +01:00
Dietmar Maurer
52878b0a38 use Digest::SHA instead of Digest::SHA1 2012-03-20 12:33:38 +01:00
Dietmar Maurer
937515d61b add permissions for backup API 2012-02-06 08:17:25 +01:00
Dietmar Maurer
4baf5d13d1 use new syntax for PVE::JSONSchema::get_options 2011-11-24 12:22:24 +01:00
Dietmar Maurer
31aef76131 cleanup vzdump backup/cron code 2011-10-31 08:47:18 +01:00
Dietmar Maurer
b0905e3a84 use vzdump.cron instead of vzdump 2011-10-31 07:33:04 +01:00
Dietmar Maurer
53c6bb6cde add delete option to backup api 2011-10-28 07:59:00 +02:00
Dietmar Maurer
7625ea19ee use starttime hh:mm instead of hour and minute 2011-10-27 09:44:24 +02:00
Dietmar Maurer
063bb19ba8 correctly quote shell arguments inside vzdump cron file 2011-10-25 13:09:49 +02:00
Dietmar Maurer
ac27b58d10 finnish and cleanup vzdump API 2011-10-25 09:28:55 +02:00