Skip to content

Commit

Permalink
sigh
Browse files Browse the repository at this point in the history
  • Loading branch information
clux committed Jul 21, 2021
1 parent 64e1492 commit d81a505
Showing 1 changed file with 7 additions and 1 deletion.
8 changes: 7 additions & 1 deletion kube/src/config/incluster_config.rs
Expand Up @@ -20,7 +20,12 @@ pub fn kube_server() -> Option<String> {
}

pub fn kube_dns() -> http::Uri {
http::Uri::builder().scheme("https").authority(SERVICE_DNS).build().unwrap()
http::Uri::builder()
.scheme("https")
.authority(SERVICE_DNS)
.path_and_query("/")
.build()
.unwrap()
}

fn kube_host() -> Option<String> {
Expand Down Expand Up @@ -51,6 +56,7 @@ fn test_kube_host() {
let expected = "fake.io";
env::set_var(SERVICE_HOSTENV, expected);
assert_eq!(kube_host().unwrap(), expected);
kube_dns(); // verify kube_dns always unwraps
}

#[test]
Expand Down

0 comments on commit d81a505

Please sign in to comment.