add --chain-id to sentryd

This commit is contained in:
Bryan Stitt 2023-01-24 04:17:39 -08:00
parent 17c446b68c
commit 953bb27adc
2 changed files with 5 additions and 3 deletions

@ -257,8 +257,6 @@ fn main() -> anyhow::Result<()> {
error!("Failed sending panic to pagerduty: {}", err);
}
}));
} else {
info!("No pagerduty key. Using default panic handler");
}
// set up tokio's async runtime

@ -14,6 +14,10 @@ pub struct PagerdutySubCommand {
/// short description of the alert
summary: String,
/// the chain id to require. Only used if not using --config.
#[argh(option)]
chain_id: Option<u64>,
#[argh(option)]
/// the class/type of the event
class: Option<String>,
@ -56,7 +60,7 @@ impl PagerdutySubCommand {
})
.unwrap_or_else(|| {
pagerduty_alert(
None,
self.chain_id,
self.class,
"web3-proxy".to_string(),
None,