Commit c169298 0 parents commit c169298 Copy full SHA for c169298
File tree 4 files changed +37
-0
lines changed
4 files changed +37
-0
lines changed Original file line number Diff line number Diff line change
1
+ FROM python:3.8.3-buster
2
+
3
+ WORKDIR /app
4
+
5
+ RUN python3 -m venv /opt/venv
6
+
7
+ RUN /opt/venv/bin/pip install ginza
8
+ RUN /opt/venv/bin/pip install Flask
9
+
10
+ COPY src .
11
+
12
+ ENV FLASK_APP=server.py
13
+
14
+ ENTRYPOINT /bin/bash -c "source /opt/venv/bin/activate; flask run --host 0.0.0.0"
Original file line number Diff line number Diff line change
1
+ version : " 3.7"
2
+
3
+ services :
4
+ ginza :
5
+ build :
6
+ context : .
7
+ dockerfile : ./Dockerfile
8
+ volumes :
9
+ - ./src:/app
10
+ networks :
11
+ - app_backend
12
+ ports :
13
+ - 5000:5000
14
+
15
+ networks :
16
+ app_backend :
17
+ driver : bridge
Original file line number Diff line number Diff line change
1
+ from flask import Flask
2
+ app = Flask (__name__ )
3
+
4
+ @app .route ('/' )
5
+ def hello_world ():
6
+ return 'Hello, World!'
You can’t perform that action at this time.
0 commit comments