manager cli: output more info when transforming prune jobs
Signed-off-by: Thomas Lamprecht <t.lamprecht@proxmox.com>
This commit is contained in:
parent
6d89534929
commit
3dc8783af7
|
@ -198,7 +198,7 @@ pub(crate) fn update_to_prune_jobs_config() -> Result<(), Error> {
|
||||||
"dropping prune job without schedule from datastore '{store}' in datastore.cfg"
|
"dropping prune job without schedule from datastore '{store}' in datastore.cfg"
|
||||||
);
|
);
|
||||||
} else {
|
} else {
|
||||||
eprintln!("ignoring empty prune job of datastore {store} in datastore.cfg");
|
eprintln!("ignoring empty prune job of datastore '{store}' in datastore.cfg");
|
||||||
}
|
}
|
||||||
continue;
|
continue;
|
||||||
}
|
}
|
||||||
|
@ -207,12 +207,12 @@ pub(crate) fn update_to_prune_jobs_config() -> Result<(), Error> {
|
||||||
let mut id = format!("storeconfig-{store}");
|
let mut id = format!("storeconfig-{store}");
|
||||||
id.truncate(32);
|
id.truncate(32);
|
||||||
if data.sections.contains_key(&id) {
|
if data.sections.contains_key(&id) {
|
||||||
eprintln!("skipping existing converted prune job for datastore {store}: {id}");
|
eprintln!("skipping existing converted prune job for datastore '{store}': {id}");
|
||||||
continue;
|
continue;
|
||||||
}
|
}
|
||||||
|
|
||||||
if !options.keeps_something() {
|
if !options.keeps_something() {
|
||||||
eprintln!("dropping empty prune job of datastore {store} in datastore.cfg");
|
eprintln!("dropping empty prune job of datastore '{store}' in datastore.cfg");
|
||||||
continue;
|
continue;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -229,6 +229,10 @@ pub(crate) fn update_to_prune_jobs_config() -> Result<(), Error> {
|
||||||
|
|
||||||
data.sections
|
data.sections
|
||||||
.insert(id, ("prune".to_string(), prune_config));
|
.insert(id, ("prune".to_string(), prune_config));
|
||||||
|
|
||||||
|
eprintln!(
|
||||||
|
"migrating prune job of datastore '{store}' from datastore.cfg to prune.cfg jobs"
|
||||||
|
);
|
||||||
}
|
}
|
||||||
|
|
||||||
prune::save_config(&data)?;
|
prune::save_config(&data)?;
|
||||||
|
|
Loading…
Reference in New Issue