Merge remote-tracking branch 'origin/main' into bot

This commit is contained in:
Linus E
2022-04-04 16:41:22 +02:00
57 changed files with 2414 additions and 556 deletions

View File

@@ -1,17 +1,20 @@
FROM python:3.10-slim
# Change the working directory to the root of the project
WORKDIR /srv/flask_app
# Install the dependencies
COPY telegram_bot/requirements.txt /srv/flask_app/
RUN pip install -r requirements.txt --src /usr/local/src --no-warn-script-location
# Copy the source code to the working directory
COPY telegram_bot /srv/flask_app
RUN chmod +x ./deploy/start.sh
RUN chmod +x ./deploy/healthcheck.sh
# Change file permissions
RUN chmod +x ./deploy/start.sh
# TODO: Set healthcheck
# HEALTHCHECK --interval=15s --timeout=2s CMD ["./deploy/healthcheck.sh"]
EXPOSE 80
# Run the application
CMD ["./deploy/start.sh"]

View File

@@ -1,2 +0,0 @@
#!/usr/bin/env sh
curl -s http://localhost:80/ -o /dev/null || exit 1

View File

@@ -1,2 +1,3 @@
#!/usr/bin/env sh
python bot.py