feat: nixos side of the config #45
4 changed files with 0 additions and 31 deletions
22
Cargo.lock
generated
22
Cargo.lock
generated
|
@ -661,27 +661,6 @@ dependencies = [
|
||||||
"subtle",
|
"subtle",
|
||||||
]
|
]
|
||||||
|
|
||||||
[[package]]
|
|
||||||
name = "csv"
|
|
||||||
version = "1.2.2"
|
|
||||||
source = "registry+https://github.com/rust-lang/crates.io-index"
|
|
||||||
checksum = "626ae34994d3d8d668f4269922248239db4ae42d538b14c398b74a52208e8086"
|
|
||||||
dependencies = [
|
|
||||||
"csv-core",
|
|
||||||
"itoa",
|
|
||||||
"ryu",
|
|
||||||
"serde",
|
|
||||||
]
|
|
||||||
|
|
||||||
[[package]]
|
|
||||||
name = "csv-core"
|
|
||||||
version = "0.1.10"
|
|
||||||
source = "registry+https://github.com/rust-lang/crates.io-index"
|
|
||||||
checksum = "2b2466559f260f48ad25fe6317b3c8dac77b5bdb5763ac7d9d6103530663bc90"
|
|
||||||
dependencies = [
|
|
||||||
"memchr",
|
|
||||||
]
|
|
||||||
|
|
||||||
[[package]]
|
[[package]]
|
||||||
name = "ctor"
|
name = "ctor"
|
||||||
version = "0.1.26"
|
version = "0.1.26"
|
||||||
|
@ -2515,7 +2494,6 @@ version = "0.1.0"
|
||||||
dependencies = [
|
dependencies = [
|
||||||
"async-std",
|
"async-std",
|
||||||
"chrono",
|
"chrono",
|
||||||
"csv",
|
|
||||||
"dotenvy",
|
"dotenvy",
|
||||||
"ldap3",
|
"ldap3",
|
||||||
"lettre",
|
"lettre",
|
||||||
|
|
|
@ -34,9 +34,6 @@ rand = "0.8.5"
|
||||||
# fancy time stuff
|
# fancy time stuff
|
||||||
chrono = "0.4.26"
|
chrono = "0.4.26"
|
||||||
|
|
||||||
# handlign teh csv export from wolves
|
|
||||||
csv = "1.2"
|
|
||||||
|
|
||||||
# for email
|
# for email
|
||||||
lettre = "0.10.4"
|
lettre = "0.10.4"
|
||||||
maud = "0.25.0"
|
maud = "0.25.0"
|
||||||
|
|
|
@ -50,7 +50,6 @@
|
||||||
# basic server stuff
|
# basic server stuff
|
||||||
HOME = cfg.home;
|
HOME = cfg.home;
|
||||||
DATABASE = "database.db";
|
DATABASE = "database.db";
|
||||||
CSV = "wolves.csv";
|
|
||||||
HOST_PORT = cfg.host_port;
|
HOST_PORT = cfg.host_port;
|
||||||
SSH_ROOT = "skynet_old";
|
SSH_ROOT = "skynet_old";
|
||||||
|
|
||||||
|
|
|
@ -180,7 +180,6 @@ pub struct Config {
|
||||||
pub ldap_admin_pw: String,
|
pub ldap_admin_pw: String,
|
||||||
pub home: String,
|
pub home: String,
|
||||||
pub database: String,
|
pub database: String,
|
||||||
pub csv: String,
|
|
||||||
pub host_port: String,
|
pub host_port: String,
|
||||||
pub mail_smtp: String,
|
pub mail_smtp: String,
|
||||||
pub mail_user: String,
|
pub mail_user: String,
|
||||||
|
@ -202,7 +201,6 @@ pub fn get_config() -> Config {
|
||||||
ldap_admin_pw: "".to_string(),
|
ldap_admin_pw: "".to_string(),
|
||||||
home: ".".to_string(),
|
home: ".".to_string(),
|
||||||
database: "database.db".to_string(),
|
database: "database.db".to_string(),
|
||||||
csv: "wolves.csv".to_string(),
|
|
||||||
host_port: "127.0.0.1:8087".to_string(),
|
host_port: "127.0.0.1:8087".to_string(),
|
||||||
mail_smtp: "".to_string(),
|
mail_smtp: "".to_string(),
|
||||||
mail_user: "".to_string(),
|
mail_user: "".to_string(),
|
||||||
|
@ -229,9 +227,6 @@ pub fn get_config() -> Config {
|
||||||
if let Ok(x) = env::var("DATABASE") {
|
if let Ok(x) = env::var("DATABASE") {
|
||||||
config.database = x.trim().to_string();
|
config.database = x.trim().to_string();
|
||||||
}
|
}
|
||||||
if let Ok(x) = env::var("CSV") {
|
|
||||||
config.csv = x.trim().to_string();
|
|
||||||
}
|
|
||||||
if let Ok(x) = env::var("HOST_PORT") {
|
if let Ok(x) = env::var("HOST_PORT") {
|
||||||
config.host_port = x.trim().to_string();
|
config.host_port = x.trim().to_string();
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in a new issue