Move data volume

This commit is contained in:
IamTheFij 2020-04-05 11:34:53 -07:00
parent 63b2fc084f
commit 9f1f6d0970

View File

@ -7,10 +7,6 @@ WORKDIR /app
COPY ./requirements-minimal.txt /app/requirements.txt
RUN pip install -r ./requirements.txt
RUN mkdir /data
VOLUME /data
ENV DB_URI sqlite:////data/fishbowl.db
EXPOSE 3000
# Install service as package for alembic
@ -18,8 +14,11 @@ COPY ./fishbowl /app/fishbowl
# Own app dir and drop root
RUN chown -R www-data:www-data /app
RUN chown -R www-data:www-data /data
USER www-data
# Make data dir
RUN mkdir /app/data
VOLUME /app/data
ENV DB_URI sqlite:////app/data/fishbowl.db
CMD ["python", "/app/fishbowl/app.py"]