aboutsummaryrefslogtreecommitdiffstats
path: root/rust/src
diff options
context:
space:
mode:
authorBryan Newbold <bnewbold@robocracy.org>2018-06-20 17:55:17 -0700
committerBryan Newbold <bnewbold@robocracy.org>2018-06-20 17:55:17 -0700
commit907a9d3b5882ec12b2c8c0563a7ed08be0edf022 (patch)
tree8e4b8c0447888a1204ac9e68bf5dbd432dc8564f /rust/src
parent43e74c2e81c64d6d4f4e644cc5a6f75945ff660d (diff)
downloadfatcat-907a9d3b5882ec12b2c8c0563a7ed08be0edf022.tar.gz
fatcat-907a9d3b5882ec12b2c8c0563a7ed08be0edf022.zip
have fatcatd declare it's port on startup
Diffstat (limited to 'rust/src')
-rw-r--r--rust/src/bin/fatcatd.rs5
1 files changed, 4 insertions, 1 deletions
diff --git a/rust/src/bin/fatcatd.rs b/rust/src/bin/fatcatd.rs
index 256027c8..4778df9e 100644
--- a/rust/src/bin/fatcatd.rs
+++ b/rust/src/bin/fatcatd.rs
@@ -70,6 +70,9 @@ fn main() {
)))
}
+ let host_port = "localhost:9411";
+ info!(logger, "Starting fatcatd API server on http://{}", &host_port);
+
let mut chain = Chain::new(LoggerMiddleware::new(router, logger, formatter));
// Auth stuff unused for now
@@ -85,7 +88,7 @@ fn main() {
} else {
// Using HTTP
Iron::new(chain)
- .http("localhost:9411")
+ .http(host_port)
.expect("Failed to start HTTP server");
}
}