docs(#1989): add # errors doc to rebuild_agent + rebuild (argus review)
This commit is contained in:
parent
1f0cc010ad
commit
678f50f3fb
2 changed files with 16 additions and 0 deletions
|
|
@ -72,6 +72,10 @@ pub fn agent_config_pending(name: &str, deployed_sha: Option<&str>) -> bool {
|
|||
/// the container rebuild. Pass `false` only for meta-update cascade
|
||||
/// rebuilds, where re-locking would revert the bump the cascade just
|
||||
/// committed (see `lifecycle::rebuild`).
|
||||
///
|
||||
/// # Errors
|
||||
///
|
||||
/// Propagates errors from `coord.ensure_runtime` and `lifecycle::rebuild`.
|
||||
pub async fn rebuild_agent(
|
||||
coord: &Arc<Coordinator>,
|
||||
name: &str,
|
||||
|
|
|
|||
|
|
@ -409,6 +409,18 @@ pub async fn destroy(name: &str) -> Result<()> {
|
|||
Ok(())
|
||||
}
|
||||
|
||||
/// Rebuild `name`'s container: sync the meta flake, optionally re-lock
|
||||
/// the agent's input, then re-apply + restart via `nixos-container`.
|
||||
///
|
||||
/// When `relock` is `true` the agent's meta input is bumped to whatever
|
||||
/// `applied/<n>/main` points at before the build. Pass `false` for
|
||||
/// meta-update cascade rebuilds, where re-locking would revert the bump
|
||||
/// the cascade just committed (see the inline note below).
|
||||
///
|
||||
/// # Errors
|
||||
///
|
||||
/// Propagates errors from meta-flake sync / lock-update and the
|
||||
/// `nixos-container` apply + restart shellouts.
|
||||
pub async fn rebuild(
|
||||
name: &str,
|
||||
hive: &HiveEnv,
|
||||
|
|
|
|||
Loading…
Reference in a new issue