Add setup.py

Add setup.py file for proper installation. Move dependency declarations
from the requirements.txt file into the setup.py to avoid duplicate
information. Make tox use the setup.py for creating test environments.

Issue: HIC-230
Change-Id: I260f0ee841f1bb00714fc20dcf352fbc4e80e25a
diff --git a/README.md b/README.md
index d008b7f..1e75f05 100644
--- a/README.md
+++ b/README.md
@@ -22,7 +22,7 @@
     $ cd hiccup-server
     $ virtualenv -p python3.6 .venv/hiccupenv
     $ source .venv/hiccupenv/bin/activate
-    (hiccupenv) $ pip install -r requirements.txt
+    (hiccupenv) $ pip install -e .
 
 When using a virtualenv with pyenv (e.g. to get python3.6 on Ubuntu 16.04),
 the python executable needs to be explicitly named to make tox work (see
diff --git a/requirements.txt b/requirements.txt
deleted file mode 100644
index 6941c45..0000000
--- a/requirements.txt
+++ /dev/null
@@ -1,36 +0,0 @@
-certifi==2018.8.24
-chardet==3.0.4
-coreapi==2.3.3
-coreschema==0.0.4
-defusedxml==0.5.0
-Django==1.11.14
-django-allauth==0.36.0
-django-bootstrap-form==3.4
-django-bootstrap3==10.0.1
-django-crispy-forms==1.7.2
-django-extensions==2.1.0
-django-filter==2.0.0
-django-frontend==1.8.0
-django-frontend-skeleton==3.0.0
-django-taggit==0.22.2
-djangorestframework==3.8.2
-drf-yasg==1.10.0
-future==0.16.0
-idna==2.7
-inflection==0.3.1
-itypes==1.1.0
-Jinja2==2.10
-MarkupSafe==1.0
-oauthlib==2.1.0
-openapi-codec==1.3.2
-pluggy==0.7.1
-psycopg2==2.7.5
-py==1.6.0
-python3-openid==3.1.0
-pytz==2018.5
-requests==2.19.1
-requests-oauthlib==1.0.0
-ruamel.yaml==0.15.64
-six==1.11.0
-uritemplate==3.0.0
-urllib3==1.23
diff --git a/setup.py b/setup.py
new file mode 100755
index 0000000..5bf5bcb
--- /dev/null
+++ b/setup.py
@@ -0,0 +1,55 @@
+#!/usr/bin/env python
+"""Setup.py for Hiccup server project."""
+
+from setuptools import setup, find_packages
+
+with open("README.md") as f:
+    LONG_DESCRIPTION = f.read()
+
+setup(
+    name="hiccup",
+    version="1.0",
+    description="Hiccup crash reporting server",
+    long_description=LONG_DESCRIPTION,
+    long_description_content_type="text/markdown",
+    packages=find_packages(),
+    python_requires="==3.6.*",
+    install_requires=[
+        "certifi==2018.8.24",
+        "chardet==3.0.4",
+        "coreapi==2.3.3",
+        "coreschema==0.0.4",
+        "defusedxml==0.5.0",
+        "Django==1.11.14",
+        "django-allauth==0.36.0",
+        "django-bootstrap-form==3.4",
+        "django-bootstrap3==10.0.1",
+        "django-crispy-forms==1.7.2",
+        "django-extensions==2.1.0",
+        "django-filter==2.0.0",
+        "django-frontend==1.8.0",
+        "django-frontend-skeleton==3.0.0",
+        "django-taggit==0.22.2",
+        "djangorestframework==3.8.2",
+        "drf-yasg==1.10.0",
+        "future==0.16.0",
+        "idna==2.7",
+        "inflection==0.3.1",
+        "itypes==1.1.0",
+        "Jinja2==2.10",
+        "MarkupSafe==1.0",
+        "oauthlib==2.1.0",
+        "openapi-codec==1.3.2",
+        "pluggy==0.7.1",
+        "psycopg2==2.7.5",
+        "py==1.6.0",
+        "python3-openid==3.1.0",
+        "pytz==2018.5",
+        "requests==2.19.1",
+        "requests-oauthlib==1.0.0",
+        "ruamel.yaml==0.15.64",
+        "six==1.11.0",
+        "uritemplate==3.0.0",
+        "urllib3==1.23",
+    ],
+)
diff --git a/tox.ini b/tox.ini
index 13682f8..5092cac 100644
--- a/tox.ini
+++ b/tox.ini
@@ -5,19 +5,14 @@
 
 [tox]
 envlist = py36
-# There is no proper way to install the app for now (i.e. setup.py)
-skipsdist = True
 
 [testenv]
-deps =
-    -rrequirements.txt
 commands =
     python manage.py test {posargs}
 
 # Test coverage
 [testenv:coverage]
 deps =
-    {[testenv]deps}
     coverage
 commands =
     coverage run manage.py test
@@ -43,7 +38,6 @@
 
 [testenv:pylint]
 deps =
-    -rrequirements.txt
     -rrequirements-dev-pylint.txt
 commands =
     pylint {posargs: {[linters]include_dirs}}
@@ -59,7 +53,6 @@
 # Git pre-commit hooks: Run formatter and linters
 [testenv:pre-commit-hooks]
 deps =
-    -rrequirements.txt
     -rrequirements-dev.txt
 passenv = GIT_INDEX_FILE
 commands =
@@ -86,7 +79,6 @@
 
 # Create markdown docs
 [testenv:docs]
-deps = {[testenv]deps}
 commands =
     {[docs]commands}
     java -jar swagger2markup-cli-{[docs]swagger_version}.jar convert \
@@ -97,7 +89,6 @@
 
 # Create HTML docs
 [testenv:docs-html]
-deps = {[testenv]deps}
 commands =
     {[docs]commands}
     java -jar swagger2markup-cli-{[docs]swagger_version}.jar convert \