namespace all our variables
This commit is contained in:
parent
14508183ab
commit
458f791fe3
4 changed files with 17 additions and 12 deletions
|
@ -57,8 +57,8 @@ async fn main() -> std::io::Result<()> {
|
|||
start_reaper(data.clone());
|
||||
|
||||
let static_dir =
|
||||
PathBuf::from(std::env::var("STATIC_DIR").unwrap_or_else(|_| String::from("static")));
|
||||
let port = std::env::var("PORT")
|
||||
PathBuf::from(std::env::var("TRANSBEAM_STATIC_DIR").unwrap_or_else(|_| String::from("static")));
|
||||
let port = std::env::var("TRANSBEAM_PORT")
|
||||
.ok()
|
||||
.and_then(|p| p.parse::<u16>().ok())
|
||||
.unwrap_or(8080);
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue