From 84bec924abcb5a440273f6ae593f4adb59804a93 Mon Sep 17 00:00:00 2001 From: xenofem Date: Mon, 23 May 2022 01:06:31 -0400 Subject: [PATCH] bind on ipv6 too --- src/main.rs | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/src/main.rs b/src/main.rs index 05dffcf..a69d30c 100644 --- a/src/main.rs +++ b/src/main.rs @@ -78,7 +78,8 @@ async fn main() -> std::io::Result<()> { .service(json) .service(actix_files::Files::new("/", static_dir.clone()).index_file("index.html")) }) - .bind("127.0.0.1:8080")? + .bind((std::net::Ipv4Addr::LOCALHOST, 8080))? + .bind((std::net::Ipv6Addr::LOCALHOST, 8080))? .run() .await }