fix(storage): S-06 — container advisory lock prevents parallel mount and concurrent writes

This commit is contained in:
2026-09-19 09:05:12 +02:00
parent 9634beb744
commit f9733dfc73
7 changed files with 280 additions and 3 deletions
+8
View File
@@ -253,6 +253,10 @@ enum Commands {
#[arg(short, long, default_value_t = false)]
quiet: bool,
/// Erzwingt die Synchronisation auch bei erkanntem Advisory Lock eines anderen Prozesses (S-06)
#[arg(short = 'f', long, default_value_t = false)]
force: bool,
/// Optionaler 24-Wort Notfallschlüssel (umgeht Passwortabfrage)
#[arg(long, num_args = 0..=1, default_missing_value = "")]
recovery_key: Option<String>,
@@ -1362,6 +1366,7 @@ fn handle_sync(
checksum: bool,
exclude: Vec<String>,
quiet: bool,
force: bool,
recovery_key: Option<&str>,
) -> Result<()> {
if !container_path.exists() {
@@ -1418,6 +1423,7 @@ fn handle_sync(
checksum,
exclude_patterns: exclude,
quiet,
force,
};
if !quiet {
@@ -1686,6 +1692,7 @@ async fn run() -> Result<()> {
checksum,
exclude,
quiet,
force,
recovery_key,
} => {
handle_sync(
@@ -1699,6 +1706,7 @@ async fn run() -> Result<()> {
checksum,
exclude,
quiet,
force,
recovery_key.as_deref(),
)?;
}