huskies: merge 1174 story Gateway startup announcement reports version and model
This commit is contained in:
@@ -414,12 +414,15 @@ pub async fn run_bot(
|
||||
// blip or sync resumption.
|
||||
//
|
||||
// When started by the trampoline the message is specialised:
|
||||
// - HUSKIES_TRAMPOLINE_STARTED=1 → "gateway X.Y.Z ready"
|
||||
// - HUSKIES_TRAMPOLINE_STARTED=1 → "gateway X.Y.Z (git_hash) ready — model: ..."
|
||||
// - HUSKIES_TRAMPOLINE_FAILURE=<reason> → rollback failure notice
|
||||
let announce_msg = if let Ok(reason) = std::env::var("HUSKIES_TRAMPOLINE_FAILURE") {
|
||||
super::format::format_gateway_rollback_announcement(&reason)
|
||||
} else if std::env::var("HUSKIES_TRAMPOLINE_STARTED").is_ok() {
|
||||
super::format::format_gateway_ready_announcement()
|
||||
super::format::format_gateway_ready_announcement(
|
||||
option_env!("BUILD_GIT_HASH").unwrap_or("unknown"),
|
||||
config.model.as_deref(),
|
||||
)
|
||||
} else {
|
||||
format_startup_announcement(&announce_bot_name)
|
||||
};
|
||||
|
||||
Reference in New Issue
Block a user