summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--src/auth.rs3
-rw-r--r--src/main.rs14
2 files changed, 11 insertions, 6 deletions
diff --git a/src/auth.rs b/src/auth.rs
index d5a2ffc..8178593 100644
--- a/src/auth.rs
+++ b/src/auth.rs
@@ -20,14 +20,13 @@ pub enum LoaderError {
#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
pub enum UserRole {
- User,
+ Player,
Bridge
}
#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
pub struct User {
pub name: String,
- pub email: String,
pub pass_token: String,
pub role: UserRole
}
diff --git a/src/main.rs b/src/main.rs
index 7aef6cd..af7218c 100644
--- a/src/main.rs
+++ b/src/main.rs
@@ -67,10 +67,16 @@ fn main(){
let config = config::Config::from_args();
let adresses = config.address
- .unwrap_or(vec![
- (if cfg!(target_os = "linux") {"abstract:rustifarm"} else {"unix:/tmp/rustifarm"}).parse().unwrap(),
- "inet:127.0.0.1:1234".parse().unwrap()
- ]);
+ .unwrap_or(
+ (if cfg!(target_os = "linux") {
+ vec!["abstract:rustifarm", "inet:127.0.0.1:9021"]
+ } else {
+ vec!["inet:127.0.0.1:9021"]
+ })
+ .iter()
+ .map(|a| a.parse().unwrap())
+ .collect()
+ );
println!("adresses: {:?}", adresses);
let servers: Vec<Box<dyn Server>> =
adresses