Structure of a Django project
The first thing you might notice is the project, which I just called djangoProject
, has its own set of files distinct from the application, which is in the TheGreatBookery
folder. All of the files inside of the djangoProject
folder are used in the deployment of your application to production, as well as to run the built-in development server.
Inside the TheGreatBookery
folder, we have a folder for database migrations. This is common for applications that use ORMs. You need a way to make changes to the production database as you roll new releases into production. You can’t simply drop the database and rebuild it since that would erase all your application’s data. There needs to be a system to migrate schema changes to the existing database while maintaining your existing production data. Django’s system for migrations utilizes migration scripts stored in this folder.
The templates folder, which is technically outside the application...