mirror of
https://github.com/StefBuwalda/dashboard_test.git
synced 2025-10-30 19:29:58 +00:00
Set up docker auto build, copied from another project
This commit is contained in:
17
DockerFile
Normal file
17
DockerFile
Normal file
@@ -0,0 +1,17 @@
|
|||||||
|
FROM python:3.12-slim
|
||||||
|
|
||||||
|
# Everything will be done in /app (Not in the main OS Image)
|
||||||
|
WORKDIR /app
|
||||||
|
|
||||||
|
COPY requirements.txt .
|
||||||
|
|
||||||
|
RUN pip install --no-cache-dir -r requirements.txt
|
||||||
|
|
||||||
|
COPY . .
|
||||||
|
|
||||||
|
RUN chmod +x ./entrypoint.sh
|
||||||
|
|
||||||
|
ENV FLASK_APP=app.py
|
||||||
|
|
||||||
|
ENTRYPOINT ["./entrypoint.sh"]
|
||||||
|
CMD []
|
||||||
8
entrypoint.sh
Normal file
8
entrypoint.sh
Normal file
@@ -0,0 +1,8 @@
|
|||||||
|
#!/bin/sh
|
||||||
|
set -ex
|
||||||
|
|
||||||
|
#echo "Running database migrations..."
|
||||||
|
#flask db upgrade
|
||||||
|
|
||||||
|
echo "Starting Flask app..."
|
||||||
|
python app.py
|
||||||
Reference in New Issue
Block a user