I am really excited to present this Django tutorial, made with Django 1.8 and Python 3.
In this tutorial, I will show you how to create a Django Project from scratch.
I will focus in a simple Task manager project, but the idea is that you can follow this tutorial while building your own project.
Specially during the first posts. And you will be able to download a Django Project Boilerplate too! 🙂
However, this is not a common Django tutorial.
It is much better: it is like a check list to create a complex Django project.
You will learn about security issues, different environments for developing and testing, version control repositories, deployment on Heroku, PostgreSQL configuration, and many more things!
Moreover, while building the TaskBuster project, I’ll try to cover as many Django Best Practices as I can.
Enjoy, and learn as much as you can! 🙂
Ah, and let me introduce you to our main character, you will find it around through this tutorial. It’s a Python with an interesting Hat…
Yeah, that’s our Django pet!
Many thanks to Enric Melé for the design 🙂
Part I – Working environment and start a Django Project
- Building your Working environment
- Install Django 1.8
- Working directory and Sublime Text
- Obey the Testing Goat
- Create a Django project
- Start a development server
- Virtual environments and requirements files
- Different settings.py for each enviroment
- Production settings.py – Debug False
- Django security and the Secret Key
- Initialize a Git repository and Commit
- Upload your project into Bitbucket
- Static Files Settings
- Templates Settings
- Initializr: HTML5 Boilerplate and Twitter Bootstrap
- Home Page with TDD – Tests first
- Home Page with TDD – Code next
- Commit again to your local repository and Bitbucket
Part IV – Template Inheritance, Website files and Testing with coverage
Part V – Internationalization and Localization. Languages and Time zones
Part VI – Documenting the TaskBuster Django Boilerplate
TaskBuster Django Project Boilerplate
Part VII.a – Install and Configure PostgreSQL
Part VII.b – Install and Configure MySQL
- Install MySQL
- Create a MySQL Database
- Install the MySQL Django adapter, psycopg2
- Configure the Django Database Settings
- MySQL Workbench
Part VIII – User Authentication with a Google Account using Django Allauth
- Define what we expect and write a Test
- Install django-allauth
- Settings File
- Database migrations
- Sites configuration
- Google App registration
- Allauth Django configuration
- Testing the user flow
Part VIII.b – User Authentication with Twitter using Django Allauth
Part IX – Model creation, OneToOne relations, signals and the Django Admin
- UML Diagram of the TaskManager app
- Create the TaskManager app
- Profile Model: OneToOne relationship with the User Model
- Django Signals: create a Profile instance when a new user is created
- The Django Admin for the Profile Model
Please, add +Marina Mele in your comments. This way I will get a notification email and I will answer you as soon as possible! :-)