diff --git a/.gitignore b/.gitignore new file mode 100644 index 0000000..619b135 --- /dev/null +++ b/.gitignore @@ -0,0 +1,94 @@ +### https://raw.github.com/github/gitignore/0f88fa75def7ed7d96935b8630793e51953df9b0/Python.gitignore + +# Byte-compiled / optimized / DLL files +__pycache__/ +*.py[cod] +*$py.class + +# C extensions +*.so + +# Distribution / packaging +.Python +env/ +build/ +develop-eggs/ +dist/ +downloads/ +eggs/ +.eggs/ +lib/ +lib64/ +parts/ +sdist/ +var/ +*.egg-info/ +.installed.cfg +*.egg + +# PyInstaller +# Usually these files are written by a python script from a template +# before PyInstaller builds the exe, so as to inject date/other infos into it. +*.manifest +*.spec + +# Installer logs +pip-log.txt +pip-delete-this-directory.txt + +# Unit test / coverage reports +htmlcov/ +.tox/ +.coverage +.coverage.* +.cache +nosetests.xml +coverage.xml +*,cover +.hypothesis/ + +# Translations +*.mo +*.pot + +# Django stuff: +*.log +local_settings.py + +# Flask stuff: +instance/ +.webassets-cache + +# Scrapy stuff: +.scrapy + +# Sphinx documentation +docs/_build/ + +# PyBuilder +target/ + +# Jupyter Notebook +.ipynb_checkpoints + +# pyenv +.python-version + +# celery beat schedule file +celerybeat-schedule + +# dotenv +.env + +# virtualenv +.venv/ +venv/ +ENV/ + +# Spyder project settings +.spyderproject + +# Rope project settings +.ropeproject + + diff --git a/Dockerfile b/Dockerfile new file mode 100644 index 0000000..0186574 --- /dev/null +++ b/Dockerfile @@ -0,0 +1,10 @@ +FROM python:alpine3.6 + +COPY . /usr/src/app +WORKDIR /usr/src/app + +RUN pip install --no-cache-dir -r /usr/src/app/requirements.txt + +EXPOSE 80 + +CMD python3 main.py diff --git a/main.py b/main.py new file mode 100644 index 0000000..0a16148 --- /dev/null +++ b/main.py @@ -0,0 +1,11 @@ +#!/usr/bin/env python3 + +from aiohttp import web + +async def handle(request): + return web.Response(text='O hai') + +app = web.Application() +app.router.add_get('/', handle) + +web.run_app(app, port=80) diff --git a/requirements.txt b/requirements.txt new file mode 100644 index 0000000..ef1e2f1 --- /dev/null +++ b/requirements.txt @@ -0,0 +1 @@ +aiohttp==2.2.5