Preparation for usage on vessel, pyinstaller

This commit is contained in:
Kumi 2022-04-19 08:54:28 +02:00
parent 3c10f3c70c
commit 1db908399e
Signed by: kumi
GPG key ID: 5D1CE6AF1805ECA2
4 changed files with 14 additions and 4 deletions

3
.gitignore vendored
View file

@ -3,3 +3,6 @@ venv/
__pycache__/
maildir/
*.pem
build/
dist/
*.spec

View file

@ -1 +1,2 @@
aiosmtpd
pyopenssl

View file

@ -2,5 +2,5 @@
maildir = maildir
[USERS]
test = $argon2id$v=19$m=65536,t=3,p=4$0ZfYHQjV5IlHxtPqKP5O7A$LZ/vfXP1QoymVaPwwhH/0+FOK+Ek5fwr7YC98/E402A
test = $6$GCsvefFgXbOm7hyT$uYal5FY5iMsksr2zCUHIAfR1i7rqLEqJxNbqAlcBmK/3npjeLZsfvRKn8KI7yAiWLZL6.8xWRAh0KxslEfed80

View file

@ -4,6 +4,8 @@ from aiosmtpd.smtp import AuthResult
import asyncio
import logging
from argparse import ArgumentParser
from classes.smtpdhandler import SmtpdHandler
from classes.config import Config
from classes.authenticator import Authenticator
@ -12,10 +14,14 @@ from classes.ssl import SSL
if __name__ == "__main__":
log = logging.basicConfig()
parser = ArgumentParser()
parser.add_argument("-c", "--config", help="Path to config file", default="settings.ini")
args = parser.parse_args()
loop = asyncio.new_event_loop()
asyncio.set_event_loop(loop)
config = Config("settings.ini")
config = Config(args.config)
authenticator = Authenticator(config)
handler = SmtpdHandler(config)