Commit Graph

6 Commits

Author SHA1 Message Date
Thomas Lamprecht
63d389bc51 api: backup info: make "name" property truly optional in response struct
avoid returning a nullish/undef value if not specified

Signed-off-by: Thomas Lamprecht <t.lamprecht@proxmox.com>
2022-11-15 14:07:39 +01:00
Thomas Lamprecht
fc9991245f api: backup info: code/style cleanup/rework/modernization
Signed-off-by: Thomas Lamprecht <t.lamprecht@proxmox.com>
2022-11-15 14:07:39 +01:00
Thomas Lamprecht
730d5a0f42 api: backup info: drop querying rrd_dump, not used
Signed-off-by: Thomas Lamprecht <t.lamprecht@proxmox.com>
2022-11-15 14:07:39 +01:00
Thomas Lamprecht
0d3f86f2a4 api: backup info: rework get_included_vmids code style
Signed-off-by: Thomas Lamprecht <t.lamprecht@proxmox.com>
2022-11-15 14:07:39 +01:00
Dominik Csapak
305921b1ab api/backup: handle new vzdump jobs
in addition to listing the vzdump.cron jobs, also list from the
jobs.cfg file.

updates/creations go into the new jobs.cfg only now
and on update, starttime+dow get converted to a schedule
this transformation is straight forward, since 'dow'
is already in a compatible format (e.g. 'mon,tue') and we simply
append the starttime (if any)

id on creation is optional for now (for api compat), but will
be autogenerated (uuid). on update, we simply take the id from before
(the ids of the other entries in vzdump.cron will change but they would
anyway)

as long as we have the vzdump.cron file, we must lock both
vzdump.cron and jobs.cfg, since we often update both

we also change the backupinfo api call to read the jobs.cfg too

Signed-off-by: Dominik Csapak <d.csapak@proxmox.com>
2021-11-10 16:11:00 +01:00
Thomas Lamprecht
df6f4b1874 move BackupInfo module into Cluster
no semantic change regarding API or the like intended

Signed-off-by: Thomas Lamprecht <t.lamprecht@proxmox.com>
2021-07-02 12:50:49 +02:00