Skip to content

Commit

Permalink
Initial commit. No idea if it works
Browse files Browse the repository at this point in the history
  • Loading branch information
kiriappeee committed Aug 2, 2018
0 parents commit 16888f3
Show file tree
Hide file tree
Showing 6 changed files with 44 additions and 0 deletions.
7 changes: 7 additions & 0 deletions Dockerfile
@@ -0,0 +1,7 @@
FROM python:3.5

COPY requirements.txt /tmp/requirements.txt
RUN pip install -r /tmp/requirements.txt
ADD src/ /src
WORKDIR /src
EXPOSE 5000
4 changes: 4 additions & 0 deletions Dockerfile.nginx
@@ -0,0 +1,4 @@
FROM nginx

COPY nginx.conf /etc/nginx/conf.d/default.conf
EXPOSE 80
15 changes: 15 additions & 0 deletions docker-compose.yml
@@ -0,0 +1,15 @@
version: "2"
services:
revproxy:
build:
context: "."
file: "Dockerfile.nginx"
links:
- "web"
ports:
- "80:80"
web:
build:
context: "."
file: "Dockerfile"
command: "FLASK_APP=app.py flask run --host 0.0.0.0"
6 changes: 6 additions & 0 deletions nginx.conf
@@ -0,0 +1,6 @@
server{
listen 80;
location / {
proxy_pass web:5000
}
}
6 changes: 6 additions & 0 deletions requirements.txt
@@ -0,0 +1,6 @@
click==6.7
Flask==1.0.2
itsdangerous==0.24
Jinja2==2.10
MarkupSafe==1.0
Werkzeug==0.14.1
6 changes: 6 additions & 0 deletions src/app.py
@@ -0,0 +1,6 @@
from flask import Flask
app = Flask(__name__)

@app.route('/')
def hello_world():
return 'Hello, World!'

0 comments on commit 16888f3

Please sign in to comment.