0.29.7
This commit is contained in:
1 parent
ad95bfb050
commit
1431dd47f0
62 files changed
+1360
-198
No files matched your search
+5
-2
@@ -4,7 +4,7 @@ use crate::{
|
||||
headers::HeaderRules,
|
||||
security::SecurityHeaders,
|
||||
};
|
||||
use anyhow::{ensure, Result};
|
||||
use anyhow::{ensure, Context, Result};
|
||||
use serde::{Deserialize, Serialize};
|
||||
use std::net::{IpAddr, SocketAddr};
|
||||
fn yes() -> bool {
|
||||
@@ -156,7 +156,6 @@ pub struct PathRewrite {
|
||||
pub mode: RewriteMode,
|
||||
pub value: String,
|
||||
}
|
||||
|
||||
fn response_status() -> u16 {
|
||||
200
|
||||
}
|
||||
@@ -403,6 +402,10 @@ pub struct PoolMember {
|
||||
pub backup: bool,
|
||||
#[serde(default)]
|
||||
pub drain: bool,
|
||||
#[serde(default = "yes")]
|
||||
pub health_check_enabled: bool,
|
||||
#[serde(default, skip_serializing_if = "Option::is_none")]
|
||||
pub health_check: Option<crate::balance::HealthCheck>,
|
||||
#[serde(default)]
|
||||
pub allow_private: bool,
|
||||
#[serde(default)]
|
||||
|
||||
@@ -217,6 +217,13 @@ impl Vhost {
|
||||
}
|
||||
}
|
||||
self.load_balancing.validate()?;
|
||||
for member in &self.backends {
|
||||
if let Some(custom) = &member.health_check {
|
||||
let mut settings = self.load_balancing.clone();
|
||||
settings.health_check = custom.clone();
|
||||
settings.validate().with_context(|| format!("backend {} health check", member.id))?;
|
||||
}
|
||||
}
|
||||
self.proxy_timeouts.validate()?;
|
||||
self.rate_limit.validate()?;
|
||||
if let Some(policy) = &self.tls_policy {
|
||||
|
||||
Reference in new issue
Block a user