all repos — albus @ e8a05b5fc1f191a9c57c6d985dae93e65c150baf

Dockerfile (view raw)

 1# Use the Alpine Linux base image
 2FROM alpine:latest
 3
 4# Install dependencies
 5RUN apk update && \
 6    apk add --no-cache \
 7    pandoc \
 8    python3 \
 9    py3-pip \
10    build-base \
11    tectonic
12
13# Set the working directory
14WORKDIR /app
15
16# Copy the requirements.txt file and install Python dependencies
17COPY requirements.txt .
18
19RUN pip install --no-cache-dir --break-system-packages -r requirements.txt
20
21# Copy the rest of the application code
22COPY albus albus
23
24# Add a non-root user and use it
25RUN adduser -D appuser && \
26    chown -R appuser /app
27USER appuser
28
29# Set the entrypoint to your application or provide a command for the container to run
30CMD ["python", "-m", "albus.bot"]