Added Kubernetes API support, fo ingress controller.

This commit is contained in:
Ara Sadoyan
2025-09-01 16:32:30 +02:00
parent e304482667
commit d3602fa578
14 changed files with 434 additions and 228 deletions

View File

@@ -21,6 +21,12 @@ pub struct Extraparams {
pub authentication: DashMap<String, Vec<String>>,
pub rate_limit: Option<isize>,
}
#[derive(Clone, Default, Debug, Serialize, Deserialize)]
pub struct Kubernetes {
pub servers: Option<Vec<String>>,
pub services: Option<Vec<ServiceMapping>>,
pub tokenpath: Option<String>,
}
#[derive(Clone, Default, Debug, Serialize, Deserialize)]
pub struct Consul {
@@ -44,6 +50,8 @@ pub struct Config {
#[serde(default)]
pub consul: Option<Consul>,
#[serde(default)]
pub kubernetes: Option<Kubernetes>,
#[serde(default)]
pub rate_limit: Option<isize>,
}
@@ -65,6 +73,7 @@ pub struct Configuration {
pub upstreams: UpstreamsDashMap,
pub headers: Headers,
pub consul: Option<Consul>,
pub kubernetes: Option<Kubernetes>,
pub typecfg: String,
pub extraparams: Extraparams,
}