canic_host/install_root/
options.rs1use crate::{
2 canister_build::CanisterBuildProfile,
3 deployment_truth::{ArtifactPromotionPlanV1, DeploymentPlanV1},
4};
5use std::path::PathBuf;
6
7#[derive(Clone, Debug)]
12pub struct InstallRootOptions {
13 pub root_canister: String,
14 pub root_build_target: String,
15 pub environment: String,
16 pub deployment_name: Option<String>,
17 pub icp_root: Option<PathBuf>,
18 pub build_profile: Option<CanisterBuildProfile>,
19 pub ready_timeout_seconds: u64,
20 pub config_path: Option<String>,
21 pub expected_fleet: Option<String>,
22 pub interactive_config_selection: bool,
23 pub deployment_plan_override: Option<DeploymentPlanV1>,
24 pub artifact_promotion_plan_override: Option<ArtifactPromotionPlanV1>,
25}
26
27impl InstallRootOptions {
28 pub(super) fn artifact_environment(&self) -> &str {
30 if self.deployment_plan_override.is_some() {
31 &self.environment
32 } else {
33 "local"
34 }
35 }
36}