Skip to content

Commit cbe4669

Browse files
committed
Add example-flask-upload
1 parent a9a3535 commit cbe4669

File tree

3 files changed

+19
-0
lines changed

3 files changed

+19
-0
lines changed

example-flask-upload/Dockerfile

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,3 @@
1+
FROM tiangolo/uwsgi-nginx-flask:flask-upload
2+
3+
COPY ./app /app

example-flask-upload/app/main.py

Lines changed: 9 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,9 @@
1+
from flask import Flask
2+
app = Flask(__name__)
3+
4+
@app.route("/")
5+
def hello():
6+
return "Hello World from Flask"
7+
8+
if __name__ == "__main__":
9+
app.run(host='0.0.0.0', debug=True, port=80)

example-flask-upload/app/uwsgi.ini

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,7 @@
1+
[uwsgi]
2+
socket = /tmp/uwsgi.sock
3+
chown-socket = nginx:nginx
4+
chmod-socket = 664
5+
6+
module = main
7+
callable = app

0 commit comments

Comments
 (0)