Skip to content

Commit 0fe7dd2

Browse files
committed
add host OS to test_whole_system_* planner tests
1 parent 07c198f commit 0fe7dd2

File tree

3 files changed

+444
-137
lines changed

3 files changed

+444
-137
lines changed

nexus/reconfigurator/planning/src/mgs_updates/host_phase_1.rs

Lines changed: 11 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -6,6 +6,7 @@
66
77
use super::MgsUpdateStatus;
88
use super::MgsUpdateStatusError;
9+
use gateway_client::types::SpType;
910
use nexus_types::deployment::BlueprintArtifactVersion;
1011
use nexus_types::deployment::BlueprintHostPhase2DesiredContents;
1112
use nexus_types::deployment::PendingMgsUpdate;
@@ -230,6 +231,16 @@ pub(super) fn try_make_update(
230231
);
231232
return None;
232233
};
234+
235+
// Only configure host OS updates for sleds.
236+
//
237+
// We don't bother logging a return value of `None` for non-sleds, because
238+
// we will never attempt to configure an update for them (nor should we).
239+
match sp_info.sp_type {
240+
SpType::Sled => (),
241+
SpType::Power | SpType::Switch => return None,
242+
}
243+
233244
let Some(sled_agent) = inventory.sled_agents.iter().find(|sled_agent| {
234245
sled_agent.baseboard_id.as_ref() == Some(baseboard_id)
235246
}) else {

0 commit comments

Comments
 (0)