pub async fn resolve_binary(
source: &BinarySource,
channel: Option<UpgradeChannel>,
install_dir: &Path,
progress: &dyn ProgressReporter,
) -> Result<ResolvedBinary>Expand description
Resolve a node binary from the given source.
Returns a ResolvedBinary containing the binary path, version string, and
an optional path to bootstrap_peers.toml if one was found alongside the binary.
For LocalPath, validates the binary exists and extracts version.
For download variants (Latest, Version, Url), downloads and caches the binary
in install_dir.
channel is the upgrade channel the resulting node will track. It only affects
Latest: a node destined for the beta channel must not be installed from a stable
release it would immediately upgrade away from, nor from a release candidate it would
never accept. None is treated as Stable, matching the node’s own default.