Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 2 additions & 0 deletions .gitignore
Original file line number Diff line number Diff line change
@@ -0,0 +1,2 @@
__pycache__
.vscode
16 changes: 8 additions & 8 deletions Dockerfile
Original file line number Diff line number Diff line change
@@ -1,8 +1,8 @@
FROM golang:1.9.2
WORKDIR /go/src/github.com/kelseyhightower/app/
COPY . .
RUN CGO_ENABLED=0 GOOS=linux go build .

FROM scratch
COPY --from=0 /go/src/github.com/kelseyhightower/app/app .
ENTRYPOINT ["/app"]
FROM python:3.6-alpine
COPY Pipfile* /app/
EXPOSE 8000
WORKDIR /app
RUN pip install pipenv flake8 gunicorn
RUN pipenv install --system --dev
COPY . /app
ENTRYPOINT ["gunicorn", "hello:app", "-b", "0.0.0.0:80"]
16 changes: 16 additions & 0 deletions Pipfile
Original file line number Diff line number Diff line change
@@ -0,0 +1,16 @@
[[source]]

url = "https://pypi.python.org/simple"
verify_ssl = true
name = "pypi"


[packages]

flask = "*"
gunicorn = "*"


[dev-packages]

pylint = "*"
156 changes: 156 additions & 0 deletions Pipfile.lock

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

7 changes: 7 additions & 0 deletions hello.py
Original file line number Diff line number Diff line change
@@ -0,0 +1,7 @@
from flask import Flask
app = Flask(__name__)


@app.route("/")
def hello():
return "Hello World!"
47 changes: 0 additions & 47 deletions main.go

This file was deleted.