-
Notifications
You must be signed in to change notification settings - Fork 0
/
Dockerfile
33 lines (24 loc) · 979 Bytes
/
Dockerfile
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
# RT Beacon - Dockerfile
ARG IMAGE=python
ARG VARIANT=3-slim
FROM ${IMAGE}:${VARIANT} AS build-env
LABEL "org.rext-dev.rt-backend-beacon.maintainer"="rext-dev"
LABEL "org.rext-dev.rt-backend-beacon.repository"="https://github.com/rext-dev/rt-backend-beacon"
WORKDIR /tmp/rt
RUN echo "Updating package repository" && \
apt update -y && apt -y upgrade
RUN echo "Preparing neccessary tools..."
RUN apt install -y --no-install-recommends build-essential python3-dev
RUN echo "Preparing requirements..."
COPY ./requirements.txt .
COPY ./core/rextlib/requirements.txt ./rextlib_requirements.txt
RUN pip3 install --no-cache-dir -U pip setuptools wheel && \
pip3 install --no-cache-dir -U -r requirements.txt -r rextlib_requirements.txt
RUN echo "Cleaning..."
RUN cd .. && rm -rf rt
RUN apt remove -y build-essential python3-dev
RUN echo "Preparing..."
COPY . /usr/local/src
WORKDIR /usr/local/src
RUN rm config.toml &> /dev/null
ENTRYPOINT ["python3", "-OO", "main.py"]