jdx/mise · error
managed system path must be absolute: {}
Error message
managed system path must be absolute: {} What it means
Managed file and directory targets go through absolute_target() -> validate_privileged_target(), which requires an absolute path. Relative paths are rejected because the privileged helper runs with a different working directory, so a relative target would resolve to a different location under root than under the invoking user.
Source
Thrown at src/system/managed_files.rs:1194
Self::File
} else if metadata.file_type().is_dir() {
Self::Directory
} else if metadata.file_type().is_symlink() {
Self::Symlink
} else {
Self::Other
}
}
}
fn absolute_target(path: &str) -> Result<PathBuf> {
let path = crate::file::replace_path(Path::new(path));
validate_privileged_target(&path)
}
fn validate_privileged_target(path: &Path) -> Result<PathBuf> {
if !path.is_absolute() {
bail!("managed system path must be absolute: {}", path.display());
}
let path = path.absolutize()?.to_path_buf();
if path == Path::new("/") {
bail!("refusing to manage the filesystem root");
}
Ok(path)
}
fn parse_mode(mode: Option<&str>, default: u32) -> Result<u32> {
let Some(mode) = mode else {
return Ok(default);
};
let mode = mode.strip_prefix("0o").unwrap_or(mode);
let parsed = u32::from_str_radix(mode, 8).wrap_err("mode must be an octal string")?;
if parsed > 0o7777 {
bail!("mode must be between 0000 and 7777");
}
Ok(parsed)View on GitHub (pinned to 9dcfcaa0dc)
Solutions
- Change the config key to an absolute path, e.g. "/etc/app/app.conf"
- If you meant a project-local file, manage it with a normal mise task or template instead of managed system files
Example fix
# before
[bootstrap.files]
"conf/app.conf" = { content = "..." }
# after
[bootstrap.files]
"/etc/app/app.conf" = { content = "...", mode = "0644" } Defensive patterns
Strategy: validation
Validate before calling
let path = std::path::Path::new(key);
if !path.is_absolute() {
return Err(eyre::eyre!("managed system path must be absolute: {key}"));
} Type guard
fn is_valid_managed_path(p: &str) -> bool {
std::path::Path::new(p).is_absolute() && p != "/"
} Prevention
- Always author managed paths as full absolute system paths
- Lint mise.toml in CI for relative keys under [bootstrap.files]/[bootstrap.directories]
When it happens
Trigger: A [bootstrap.files] or [bootstrap.directories] key like "conf/app.conf" (no leading slash) in mise.toml - anything where Path::is_absolute() is false.
Common situations: Copying a relative path from a deploy script or template into mise.toml; assuming mise prepends the project directory (it does not - targets are system paths like /etc/...).
Related errors
- bootstrap compose project names cannot be empty
- bootstrap compose project '{name}' wait_timeout requires wai
- bootstrap compose project '{name}' wait_timeout must be grea
- bootstrap compose project '{name}' oneshot services must als
- firewall port range {start}-{end} is invalid
AI-assisted analysis of jdx/mise@9dcfcaa0dc (2026-08-17).
Data as JSON: /api/errors/18c92d154f241c9e.
Report an issue: GitHub.