Matt Segal Dev

Django blog posts

A tour of Django server setups

If you haven't deployed a lot of Django apps, then you might wonder: how do professionals put Django apps on the internet? What does Django typically look like when it's running in production? You might even be thinking what the hell is production?

Before I started working a developer there …

How to diagnose and fix slow queries with Django Debug Toolbar

Your Django views are running slowly and you want to make them faster, but you can't figure out what the issue is just by reading the code. Just as bad is when you're not sure if you're using the Django ORM correctly - how can you know if the code you …

Simple Django deployment part six: domain setup

We're very nearly done deploying our Django app. There's just one more thing we should take care of. Having a raw IP as our website address is kind of yucky, isn't it? You're not going to ask your friend, boss, or mum to visit 23.231.147.88 to check …

Simple Django deployment part five: deployment automation

Deploying our Django app involved a lot of different commands, right? It would suck to have to do all that over again, wouldn't it?

Having to manually type all those commands again would be tedious, slow and easy to screw up. Even worse, the harder it is to deploy, the …

Simple Django deployment part four: run a service

So we've got a problem. Our Django app only runs when we're logged into the server via SSH and running Gunicorn. That's not going to work long term. We need to get Gunicorn running even when we're not around. In addition, if our Gunicorn server crashes because of some bug …

Simple Django deployment part three: deploy code

We've got our server set up, and our Django code is ready. Now we can actually deploy Django to our server. The goal of this section is to get a basic deployment done. We'll do some automation and introduce some extra tools later.

In this section we'll cover:

  • Windows line …

Simple Django deployment part two: local setup

We've got our server set up and ready to host our Django app, now let's focus on preparing our app for deployment. The goal of this section is to set up and test as much of the stuff that we'll be using in production. That way, we can debug issues …

Simple Django deployment part one: infrastructure

In order to deploy our Django app, we need a somewhere to run it: we need a server. In this section we'll be setting up our server in "the cloud". Doing this can be fiddly and annoying, especially if you're new, so we want to get it right first before …

Simple Django deployment: a guide

You're learning web development with Django. You've followed the official introductory tutorial and you can get a Django app working on your local computer. Now you want to put your web app onto the internet. Maybe it's to show your friends, or you actually want to use it for something …

4 tips for debugging in Django

You've got a bug in your Django code and you can't quite figure out what's wrong. You know there's a problem, but you can't quite pin down where it's coming from. This post will share 4 tips which will help you speed up your bug catching.

Dig deeper in your …

Page 2 / 3