mirror of
https://github.com/zaphar/durnitisp.git
synced 2025-07-24 18:39:49 -04:00
Configurable listen port
This commit is contained in:
parent
6f14d5d084
commit
9012e02b0e
@ -23,7 +23,7 @@ gflags::define! {
|
|||||||
|
|
||||||
gflags::define! {
|
gflags::define! {
|
||||||
/// Port to listen on for exporting variables prometheus style.
|
/// Port to listen on for exporting variables prometheus style.
|
||||||
--listenPort: u32 = 0
|
--listenHost = "0.0.0.0:8080"
|
||||||
}
|
}
|
||||||
|
|
||||||
gflags::define! {
|
gflags::define! {
|
||||||
@ -180,7 +180,7 @@ fn main() {
|
|||||||
parent.schedule(Box::new(connect_thread));
|
parent.schedule(Box::new(connect_thread));
|
||||||
}
|
}
|
||||||
let render_thread = thread::Pending::new(move || {
|
let render_thread = thread::Pending::new(move || {
|
||||||
let server = tiny_http::Server::http("localhost:8080").unwrap();
|
let server = tiny_http::Server::http(LISTENHOST.flag).unwrap();
|
||||||
loop {
|
loop {
|
||||||
eprintln!("Waiting for request");
|
eprintln!("Waiting for request");
|
||||||
match server.recv() {
|
match server.recv() {
|
||||||
|
Loading…
x
Reference in New Issue
Block a user