Files
botmafieux/Dockerfile
Mathéo 'Nebulo9' DESSAUVAGES 8cbb77be3c
Some checks failed
CI / Run tests (pull_request) Has been cancelled
feat: Reimplement the deployment process through Docker
2026-09-20 00:33:10 +02:00

36 lines
689 B
Docker

FROM python:3.13.14-alpine
RUN apk add --no-cache \
build-base \
libffi-dev \
musl-dev \
openssl-dev \
python3-dev \
geckodriver \
firefox-esr
WORKDIR /app
ENV TOKEN=""
ENV CONFIG_PATH="/config"
ENV GECKODRIVER_PATH="/usr/bin/geckodriver"
RUN adduser -D bot && \
mkdir /logs && \
chown -R bot:bot /logs && \
chmod 755 /logs && \
mkdir -p ${CONFIG_PATH} && \
chown -R bot:bot ${CONFIG_PATH} && \
chmod 755 ${CONFIG_PATH}
COPY requirements.txt .
RUN pip install --no-cache-dir -r requirements.txt
COPY . .
RUN chown -R bot:bot /app && \
chmod -R 755 /app && \
chmod +x /app/main.py
USER bot
ENTRYPOINT ["python", "main.py"]