move PruneOptions to pbs_api_types workspace

This commit is contained in:
Dietmar Maurer
2021-09-10 09:21:27 +02:00
parent e7d4be9d85
commit 89725197c0
7 changed files with 160 additions and 181 deletions

View File

@ -32,8 +32,10 @@ use pbs_buildcfg::configdir;
use pbs_systemd::time::{compute_next_event, parse_calendar_event};
use pbs_tools::logrotate::LogRotate;
use pbs_api_types::{Authid, TapeBackupJobConfig, VerificationJobConfig, SyncJobConfig, DataStoreConfig};
use pbs_datastore::prune::PruneOptions;
use pbs_api_types::{
Authid, TapeBackupJobConfig, VerificationJobConfig, SyncJobConfig, DataStoreConfig,
PruneOptions,
};
use proxmox_backup::server;
use proxmox_backup::auth_helpers::*;
@ -487,7 +489,7 @@ async fn schedule_datastore_prune() {
keep_yearly: store_config.keep_yearly,
};
if !prune_options.keeps_something() { // no prune settings - keep all
if !pbs_datastore::prune::keeps_something(&prune_options) { // no prune settings - keep all
continue;
}