Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
9 changes: 9 additions & 0 deletions crates/lib/src/cli.rs
Original file line number Diff line number Diff line change
Expand Up @@ -1493,6 +1493,15 @@ pub fn global_init() -> Result<()> {
std::env::set_var("HOME", "/root");
}
}
// Disable libdevmapper's udev synchronization. Inside a container with an
// isolated IPC namespace (the podman/docker default), udevd on the host
// cannot see the container's semaphores, causing cryptsetup luksOpen and
// luksClose to deadlock on semop(). This is a defense-in-depth measure;
// the primary fix is to run the install container with --ipc=host.
// SAFETY: Called early in main() before any threads are spawned.
unsafe {
std::env::set_var("DM_DISABLE_UDEV", "1");
}
Ok(())
}

Expand Down
6 changes: 3 additions & 3 deletions crates/lib/src/install/baseline.rs
Original file line number Diff line number Diff line change
Expand Up @@ -23,12 +23,12 @@ use clap::ValueEnum;
use fn_error_context::context;
use serde::{Deserialize, Serialize};

use super::config::Filesystem;
use super::MountSpec;
use super::RUN_BOOTC;
use super::RW_KARG;
use super::RootSetup;
use super::State;
use super::config::Filesystem;
use super::RUN_BOOTC;
use super::RW_KARG;
use crate::task::Task;
use bootc_kernel_cmdline::utf8::Cmdline;
#[cfg(feature = "install-to-disk")]
Expand Down
Loading