aboutsummaryrefslogtreecommitdiff
path: root/src/main.rs
diff options
context:
space:
mode:
authorAlex Auvolat <alex@adnab.me>2022-05-31 17:07:34 +0200
committerAlex Auvolat <alex@adnab.me>2022-05-31 17:07:34 +0200
commit553a15a82a700792986b23cb89e2a8ec070cc27d (patch)
tree8ea039322b39064fa8c66d9647f84b79f64f1921 /src/main.rs
parent01d82c14ca61e7c4de1e72c5f94456610464c064 (diff)
downloadaerogramme-553a15a82a700792986b23cb89e2a8ec070cc27d.tar.gz
aerogramme-553a15a82a700792986b23cb89e2a8ec070cc27d.zip
Implementn basic LMTP server
Diffstat (limited to 'src/main.rs')
-rw-r--r--src/main.rs12
1 files changed, 12 insertions, 0 deletions
diff --git a/src/main.rs b/src/main.rs
index b8231f1..33d3188 100644
--- a/src/main.rs
+++ b/src/main.rs
@@ -1,6 +1,7 @@
mod bayou;
mod config;
mod cryptoblob;
+mod lmtp;
mod login;
mod mail_uuid;
mod mailbox;
@@ -35,6 +36,11 @@ enum Command {
#[clap(short, long, env = "CONFIG_FILE", default_value = "mailrage.toml")]
config_file: PathBuf,
},
+ /// TEST TEST TEST
+ Test {
+ #[clap(short, long, env = "CONFIG_FILE", default_value = "mailrage.toml")]
+ config_file: PathBuf,
+ },
/// Initializes key pairs for a user and adds a key decryption password
FirstLogin {
#[clap(flatten)]
@@ -125,6 +131,12 @@ async fn main() -> Result<()> {
let server = Server::new(config)?;
server.run().await?;
}
+ Command::Test { config_file } => {
+ let config = read_config(config_file)?;
+
+ let server = Server::new(config)?;
+ server.test().await?;
+ }
Command::FirstLogin {
creds,
user_secrets,