unwind/Dockerfile

31 lines
643 B
Text
Raw Normal View History

FROM docker.io/library/python:3.10-alpine
RUN apk update --no-cache \
&& apk upgrade --no-cache \
&& pip install --no-cache-dir --upgrade pip
RUN addgroup -g 10001 py \
&& adduser -D -u 10000 -G py py
WORKDIR /var/app
COPY requirements.txt ./
# Required to build greenlet on Alpine, dependency of SQLAlchemy 1.4.
RUN apk add --no-cache \
--virtual .build-deps \
g++ gcc musl-dev \
&& pip install --no-cache-dir --upgrade \
--requirement requirements.txt \
&& apk del .build-deps
USER 10000:10001
COPY . ./
ENV UNWIND_DATA="/data"
VOLUME ["/data"]
ENTRYPOINT ["/var/app/run"]
CMD ["server"]