Skip to content

Commit 83ba1c7

Browse files
authored
Merge pull request #153 from dfinity/igor/rl-token-new-custom-domains
fix(BOUN-1501): Pass ratelimit bypass token to new custom domains
2 parents 0692891 + 724ef47 commit 83ba1c7

File tree

3 files changed

+39
-38
lines changed

3 files changed

+39
-38
lines changed

Cargo.lock

Lines changed: 34 additions & 33 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

Cargo.toml

Lines changed: 2 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -38,8 +38,8 @@ cloudflare = { version = "0.14.0", default-features = false, features = [
3838
] }
3939
console-subscriber = { version = "0.4.1", optional = true }
4040
ctrlc = { version = "3.4.5", features = ["termination"] }
41-
custom-domains-backend = { package = "backend", git = "https://github.com/dfinity/custom-domains", rev = "c839322dccaaa36a4991cba142435d12cdba4c93" }
42-
custom-domains-base = { package = "base", git = "https://github.com/dfinity/custom-domains", rev = "c839322dccaaa36a4991cba142435d12cdba4c93" }
41+
custom-domains-backend = { package = "backend", git = "https://github.com/dfinity/custom-domains", rev = "d672fec312348373eff59cdef06705487bb1da18" }
42+
custom-domains-base = { package = "base", git = "https://github.com/dfinity/custom-domains", rev = "d672fec312348373eff59cdef06705487bb1da18" }
4343
derive-new = "0.7.0"
4444
fqdn = { version = "0.4.1", features = ["serde"] }
4545
futures = "0.3.31"
@@ -128,9 +128,6 @@ wat = "1.228.0"
128128
[patch.crates-io]
129129
# v0.3.3 breaks backwards compatibility, do not remove unless you want to deal with it.
130130
ic-management-canister-types = { git = "https://github.com/dfinity/cdk-rs", rev = "19fdcd4c928b71d010aa124e2bb7f874290edac9" }
131-
# Temporary use fixed branch until new version is released.
132-
# See https://github.com/programatik29/axum-server/issues/170
133-
axum-server = { git = "https://github.com/AlvaroParker/axum-server", branch = "fix-trait-bound" }
134131

135132
[profile.release]
136133
strip = "symbols"

src/core.rs

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -191,6 +191,7 @@ pub async fn main(
191191
&mut tasks,
192192
&mut certificate_providers,
193193
&mut custom_domain_providers,
194+
cli.rate_limit.rate_limit_bypass_token.clone(),
194195
)
195196
.await
196197
.context("unable to setup Custom Domains")?;
@@ -382,6 +383,7 @@ async fn setup_custom_domains(
382383
tasks: &mut TaskManager,
383384
certificate_providers: &mut Vec<Arc<dyn ProvidesCertificates>>,
384385
custom_domain_providers: &mut Vec<Arc<dyn ProvidesCustomDomains>>,
386+
rate_limiter_bypass_token: Option<String>,
385387
) -> Result<Router, Error> {
386388
let token = tasks.token();
387389
let (workers, router, client) = setup(
@@ -390,6 +392,7 @@ async fn setup_custom_domains(
390392
token,
391393
HOSTNAME.get().unwrap(),
392394
metrics_registry.clone(),
395+
rate_limiter_bypass_token,
393396
)
394397
.await?;
395398

0 commit comments

Comments
 (0)