Skip to content

Commit

Permalink
replicate global zone /etc/default/init in new zones (#6)
Browse files Browse the repository at this point in the history
  • Loading branch information
citrus-it authored May 26, 2023
1 parent 271b5b9 commit 8708293
Showing 1 changed file with 11 additions and 0 deletions.
11 changes: 11 additions & 0 deletions brand/src/bin/brand.rs
Original file line number Diff line number Diff line change
Expand Up @@ -282,6 +282,17 @@ fn cmd_install(
extra.unpack(&root)?;
}

/*
* Copy in configuration files from the global zone.
*/
for cf in ["default/init"] {
let src = format!("/etc/{cf}");
println!("INFO: omicron: copying {src}...");
let dst = s.zonerootpath(&["etc", cf]);
std::fs::remove_file(&dst).ok();
std::fs::copy(src, dst)?;
}

println!("INFO: omicron: install complete, probably!");

Ok(())
Expand Down

0 comments on commit 8708293

Please sign in to comment.