Skip to main content

kellnr_settings/
webhooks.rs

1use provcfg::{ClapArgs, Configurable};
2use serde::{Deserialize, Serialize};
3use utoipa::ToSchema;
4
5#[derive(
6    Debug, Default, Deserialize, Serialize, Eq, PartialEq, Clone, Configurable, ClapArgs, ToSchema,
7)]
8#[serde(default)]
9#[configurable(clap_prefix = "webhooks")]
10pub struct Webhooks {
11    /// Refuse webhook deliveries to loopback, private and other non-public
12    /// addresses. Link-local and cloud metadata addresses are always refused.
13    pub block_private_targets: bool,
14    /// Connect to webhook targets directly instead of through a proxy set in
15    /// `HTTP_PROXY` or `HTTPS_PROXY`. Through a proxy, only the proxy's
16    /// address can be checked against the blocked targets.
17    pub ignore_env_proxy: bool,
18}