forked from donBarbos/telegram-bot-template
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathDockerfile
20 lines (16 loc) · 831 Bytes
/
Dockerfile
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
FROM python:3.10.5-slim
EXPOSE 8081/tcp
WORKDIR /usr/src/app
COPY . .
RUN apt update && \
apt install --no-install-recommends -y build-essential curl && \
/usr/local/bin/python -m pip install --upgrade pip && \
curl -sSL https://raw.githubusercontent.com/python-poetry/poetry/master/install-poetry.py | python - && \
export PATH="/root/.local/bin:$PATH" && \
poetry config virtualenvs.create false && \
poetry install --no-dev && \
poetry cache clear --no-interaction --all pypi && \
curl -sSL https://raw.githubusercontent.com/sdispater/poetry/master/get-poetry.py | python - --uninstall && \
apt-get -y remove build-essential curl && apt-get -y autoremove --purge && apt-get -y clean && \
rm -rf /var/lib/apt/lists/* /tmp/* /var/tmp/* /var/cache/apt
ENTRYPOINT ["python", "-m", "bot"]