From 534ad8ea88b00eb08c46a0e34575de8a815ae76e Mon Sep 17 00:00:00 2001 From: Jonathan Ervine Date: Tue, 27 Oct 2020 21:08:06 +0800 Subject: [PATCH] Launch python from shell --- Dockerfile | 2 +- smtp2slack4qnap.py | 3 +-- 2 files changed, 2 insertions(+), 3 deletions(-) diff --git a/Dockerfile b/Dockerfile index f9b9a8c..365bfd9 100644 --- a/Dockerfile +++ b/Dockerfile @@ -22,4 +22,4 @@ RUN pip3 install -r /data/requirements.txt && \ EXPOSE 1025 -CMD [ "/usr/bin/python3", "/data/smtp2slack4qnap.py" ] +CMD [ "/bin/sh", "-c", "/usr/bin/python3", "/data/smtp2slack4qnap.py" ] diff --git a/smtp2slack4qnap.py b/smtp2slack4qnap.py index 70eeef2..8c8c3d6 100644 --- a/smtp2slack4qnap.py +++ b/smtp2slack4qnap.py @@ -88,5 +88,4 @@ if __name__ == '__main__': handler = CustomHandler() controller = MyController(handler, hostname=LHOST, port=LPORT) controller.start() - -k=input('SMTP server has started ...') + input('SMTP server has started ...')