Created
October 13, 2018 02:01
-
-
Save aitoehigie/ebcc1d3e460e66cd51e5501fa2636798 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import sys | |
from django.conf import settings | |
settings.configure( | |
DEBUG=True, | |
SECRET_KEY='thisisthesecretkey', | |
ROOT_URLCONF=__name__, | |
MIDDLEWARE_CLASSES=( | |
'django.middleware.common.CommonMiddleware', | |
'django.middleware.csrf.CsrfViewMiddleware', | |
'django.middleware.clickjacking.XFrameOptionsMiddleware', | |
), | |
) | |
from django.urls import path | |
from django.http import HttpResponse | |
def index(request): | |
return HttpResponse('Hello World') | |
urlpatterns = ( | |
path('', index), | |
) | |
if __name__ == "__main__": | |
from django.core.management import execute_from_command_line | |
execute_from_command_line(sys.argv) | |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
My minimal setup: https://github.com/NekoTashi/django-pipenv-docker-minimal-setup