Rewriting our application using Django 1.7
We already created the application root folder, the same folder we installed the virtual environment in. Django provides a script that builds a standard application layout called project
, also providing some default content for the configuration file. To start a new project within the application root, we issue the following at the command line:
django/bin/django-admin.py startproject notes
We should now have a folder called notes
inside our application root containing a Python module called wsgi.py
we need to be aware of, as we will use it inside the app.yaml
file.
As we already know, to create a new App Engine application, we need to provide an app.yaml
file. We can pick any of the app.yaml
files from the previous chapters as a base, and then rewrite it as follows:
application: the_registered_application_ID version: 2 runtime: python27 api_version: 1 threadsafe: yes handlers: - url: /static static_dir: static - url: /.* script: notes.wsgi...