diff --git a/Dockerfile b/Dockerfile index 4c71317..7e35c25 100644 --- a/Dockerfile +++ b/Dockerfile @@ -1,7 +1,20 @@ -FROM tiangolo/uwsgi-nginx-flask:python3.8-alpine -RUN apk --update add bash nano -ENV STATIC_URL /static -ENV STATIC_PATH /var/www/app/static -COPY ./requirements.txt /var/www/requirements.txt -RUN pip install -r /var/www/requirements.txt +FROM python:3-alpine +# Create app directory +WORKDIR /app + +# Install app dependencies +COPY requirements.txt ./ + +RUN pip install -r requirements.txt + +#imagemagick +ENV MAGICK_HOME=/usr +RUN apk add --no-cache imagemagick && \ +apk add --no-cache imagemagick-dev + +# Bundle app source +COPY . . + +EXPOSE 8080 +CMD [ "python3", "run.py"] diff --git a/start.sh b/start.sh index 9cd5e1e..272ffc3 100644 --- a/start.sh +++ b/start.sh @@ -1,6 +1,6 @@ #!/bin/bash app="geo.app" docker build -t ${app} . -docker run --platform linux/amd64 -p 56733:80 \ +docker run --platform=linux/arm64 -p 56733:80 \ --name=${app} \ -v $PWD:/app ${app}