-
-
Notifications
You must be signed in to change notification settings - Fork 18
/
Dockerfile
32 lines (24 loc) · 754 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
FROM python:3.12-bookworm
WORKDIR /app
# Install system dependencies
RUN apt-get update && \
apt-get upgrade -y && \
apt-get install -y --no-install-recommends \
build-essential curl libpcsclite-dev clang llvm pkg-config nettle-dev \
&& rm -rf /var/lib/apt/lists/*
# Install Poetry
RUN pip install poetry
# Install Rust (for SequoiaPGP)
RUN curl --proto '=https' --tlsv1.2 -sSf https://sh.rustup.rs | sh -s -- -y
ENV PATH="/root/.cargo/bin:${PATH}"
# Install Poetry dependencies
COPY poetry.lock pyproject.toml /app/
RUN poetry install --no-root
# Copy the rest of the application
COPY . /app
RUN . ./dev_env.sh && poetry run pytest -vv /app/tests
# Expose port 8080
EXPOSE 8080
# Run!
ENV FLASK_APP="hushline"
CMD ["./start.sh"]