DEV Community

Sean
Sean

Posted on • Updated on

Project #2: Docker/Django project from testdriven.io (status: in-progress)

I started a course from Test-Driven Development with Django, Django REST Framework, and Docker

Status: Complete

2023-02-25
I haven't updated this in a while but for a good reason: I was actually doing the work and I can happily report that I have completed this project. According to my logs, I've put in 30+ hours into it and have learned a lot.

I took the TDD Django Project from testdriven and built a CI pipeline which:

  • Built a CI version of my latest code commits and ran tests and linting
  • Once those tests passed, it built a production docker image and pushed it up to GitHub Container Registry
  • If that job was successful, another job pulled down the latest images from GitHub Container Registry and copied the secret .env file + production docker-compose file and built the production image in Linode and deployed

Image description

Image description

In the end I needed 3 guides to complete this project:

2023-01-17
After getting my first build to run, I was beating my head trying to run the tests. I am trusting my gut in everything and decided to do a GitHub Actions course on Udemy. I'll go through this over the next two weeks so that I can really understand Actions. I'm not trying to piece together a buncha random StackOverflow articles. I'm doing this legit.

2023-01-12
I've been putting in time this week. In my project, added flake8/black/isort which are great packages I will use for my projects in the future. It got to a point where the tutorial wanted me to sign-up for GitLab + upload my image to Docker Hub but I wanted to use GitHub Actions + GitHub Container Registry. I watched a video from Nana Techworld and after bashing my head against the wall for an hour I finally got a passing build (though it is incomplete)!

Image description

2022-12-24
Worked on this about 1.5 hours today. It's looking good but it's quite Heroku specific, which I have no plans of using for future projects. Merry Christmas to all

2022-12-18
It's going pretty smoothly right now, I've put roughly 2.5 hours into it. The project that we build ends up deploying to Heroku but when I'm done with the project I'll try to adapt it to deploy to my Linode.

Top comments (0)