mirror of
https://github.com/miaowware/qrm2.git
synced 2026-08-14 15:33:42 -04:00
add docker deployment files
This commit is contained in:
+37
@@ -0,0 +1,37 @@
|
||||
FROM python:3-alpine
|
||||
|
||||
COPY . /app
|
||||
WORKDIR /app
|
||||
|
||||
VOLUME /app/data
|
||||
|
||||
RUN \
|
||||
echo "**** install build packages ****" && \
|
||||
apk add --no-cache --virtual=build-dependencies \
|
||||
g++ \
|
||||
git \
|
||||
gcc \
|
||||
libxml2-dev \
|
||||
libxslt-dev \
|
||||
openssl-dev \
|
||||
python3-dev && \
|
||||
echo "**** install runtime packages ****" && \
|
||||
apk add --no-cache \
|
||||
openssl \
|
||||
py3-lxml \
|
||||
py3-pip \
|
||||
python3 && \
|
||||
echo "**** install pip packages ****" && \
|
||||
pip3 install -U pip setuptools wheel && \
|
||||
pip3 install -r requirements.txt && \
|
||||
echo "**** clean up ****" && \
|
||||
apk del --purge \
|
||||
build-dependencies && \
|
||||
rm -rf \
|
||||
/root/.cache \
|
||||
/tmp/* \
|
||||
/var/cache/apk/* && \
|
||||
echo "**** prepare scripts ****" && \
|
||||
chmod +x docker-run.sh
|
||||
|
||||
CMD ["sh", "docker-run.sh", "--pass-errors"]
|
||||
Reference in New Issue
Block a user