mirror of
https://github.com/derogab/ITAvsCOVIDbot
synced 2025-01-17 01:16:48 +01:00
30 lines
764 B
Docker
30 lines
764 B
Docker
FROM python:3-alpine
|
|
|
|
# Set working space
|
|
WORKDIR /usr/src/app
|
|
|
|
# Install dependencies
|
|
RUN apk update \
|
|
# Set UTC as timezone
|
|
&& ln -snf /usr/share/zoneinfo/Europe/Rome /etc/localtime \
|
|
# Install APT packages
|
|
&& apk add gcc build-base freetype-dev libpng-dev openblas-dev wkhtmltopdf \
|
|
# Remove tmp files
|
|
&& rm -rf /tmp/* /var/tmp/* \
|
|
# Add PiWheels support
|
|
&& echo "[global]\nextra-index-url=https://www.piwheels.org/simple" >> /etc/pip.conf \
|
|
# Upgrade PIP
|
|
&& python3 -m pip install --no-cache-dir --upgrade pip
|
|
|
|
# Copy and install requirements
|
|
COPY requirements.txt .
|
|
RUN python3 -m pip install --no-cache-dir -r requirements.txt
|
|
|
|
# Copy app
|
|
COPY . .
|
|
|
|
# Create folder
|
|
RUN mkdir out
|
|
|
|
# Start the bot
|
|
CMD python3 -u bot.py |