diff --git a/Dockerfile b/Dockerfile index 228583e..533fa93 100644 --- a/Dockerfile +++ b/Dockerfile @@ -1,8 +1,9 @@ FROM alpine:latest WORKDIR /emqtt -COPY runner.py requirements.txt ./ +COPY requirements.txt ./ +RUN apk add --no-cache python3 py3-pip && pip3 install -r requirements.txt +COPY runner.py ./ COPY emqtt ./emqtt COPY tests ./tests -RUN apk add --no-cache python3 && pip3 install -r requirements.txt EXPOSE 1025 CMD ["python3", "runner.py"] diff --git a/runner.py b/runner.py index 86412dc..5f7fc6c 100755 --- a/runner.py +++ b/runner.py @@ -38,10 +38,10 @@ loop = asyncio.get_event_loop() c = Controller( - emqtt.EMQTTHandler(loop, config), - loop, - config['SMTP_LISTEN_ADDRESS'], - config['SMTP_PORT'] + handler=emqtt.EMQTTHandler(loop, config), + loop=loop, + hostname=config['SMTP_LISTEN_ADDRESS'], + port=config['SMTP_PORT'] ) c.start()