Fix docker dev db persistence (#264)

* Fix docker dev db persistence

* Make run.sh the only startup script for prod + dev

Credits to @hay-kot for run.sh script logic

* Restore dev backend initialization in non-docker setup

* Make run.sh POSIX-friendly

* Allow dev backend to auto-reload in Docker
This commit is contained in:
sephrat
2021-04-06 23:10:05 +02:00
committed by GitHub
parent 6706918736
commit a396604520
5 changed files with 24 additions and 14 deletions

View File

@@ -14,12 +14,9 @@ RUN curl -sSL https://raw.githubusercontent.com/python-poetry/poetry/master/get-
# Copy poetry.lock* in case it doesn't exist in the repo
COPY ./pyproject.toml /app/
# RUN poetry install
COPY ./mealie /app/mealie
RUN poetry install
RUN ["poetry", "run", "python", "mealie/db/init_db.py"]
RUN ["poetry", "run", "python", "mealie/services/image/minify.py"]
CMD ["poetry", "run", "python", "mealie/app.py"]
RUN chmod +x /app/mealie/run.sh
CMD /app/mealie/run.sh reload