修改docker-compose部署方式

This commit is contained in:
六翼羊王
2023-04-13 01:20:57 +08:00
parent 7e6d48510c
commit 5c9d8f4c36
5 changed files with 3 additions and 15 deletions
+1 -4
View File
@@ -1,7 +1,4 @@
FROM 1004947301/python3.7-flask:pillow
LABEL "author"="liuyiyangwang"
LABEL "blog"="https://gitee.com/liuyiyangwang"
FROM pearadminflask/python3.7-flask:pillow
COPY . /app/
COPY dockerdata/config.py /app/applications/
-3
View File
@@ -1,8 +1,5 @@
FROM python:3.7-alpine
LABEL "author"="liuyiyangwang"
LABEL "blog"="https://gitee.com/liuyiyangwang"
COPY . /app/
COPY dockerdata/config.py /app/applications/
COPY dockerdata/start.sh /app/
-3
View File
@@ -1,8 +1,5 @@
FROM python:3.7-alpine
LABEL "author"="liuyiyangwang"
LABEL "blog"="https://gitee.com/liuyiyangwang"
ENV PIPURL "https://pypi.tuna.tsinghua.edu.cn/simple/ --trusted-host pypi.douban.com"
RUN apk update \
&& apk add --virtual mysqlclient-build gcc python3-dev musl-dev \
+1 -4
View File
@@ -1,7 +1,4 @@
FROM 1004947301/python3.7-flask:pillow
LABEL "author"="liuyiyangwang"
LABEL "blog"="https://gitee.com/liuyiyangwang"
FROM pearadminflask/python3.7-flask:pillow
COPY . /app/
COPY dockerdata/config.py /app/applications/
+1 -1
View File
@@ -1,7 +1,7 @@
#!/bin/sh
sleep 5 #等MySQL启动
flask db init && flask db migrate && flask db upgrade && flask admin init
exec gunicorn -c gunicorn.conf.py "applications:create_app()"
exec gunicorn -c gunicorn.conf.py "applications:create_app() --preload"
while true; do
echo '发生错误'
sleep 100