Featured Image

Deploying Django Application on AWS EC2 and Docker

Totoro — With logo colors (AWS, Nginx, Guinicorn, and Django) If you are here, you are probably looking to deploy a Django project using AWS EC2 and docker without an orchestrator (ECS, EKS, or Docker Swarm – don’t use swarm), you are at the right place. PS: I’d still recommend using Kubernetes or at least ECS in the longer run! Let’s get started 🤪 This post assumes that you are familiar w...

Totoro — With logo colors (AWS, Nginx, Guinicorn, and Django) If you are here, you are probably looking to deploy a Django project using AWS EC2 and docker without an orchestrator (ECS, EKS, or Docker Swarm – don’t use swarm), you are at the right place. PS: I’d still recommend using Kubernete...

Read more
Featured Image

Dockerizing Django Application — Gunicorn and Nginx

Totoro — With logo colors (AWS, Docker, Nginx, Guinicorn, and Django) A step-by-step tutorial on dockerizing a Django application with MySQL database using Guinicorn and Nginx. This post assumes that you have some familiarity with Django and likely have a local Django development project, and looking at how to deploy the project in production. In the later section of the post, we’ll see how...

Totoro — With logo colors (AWS, Docker, Nginx, Guinicorn, and Django) A step-by-step tutorial on dockerizing a Django application with MySQL database using Guinicorn and Nginx. This post assumes that you have some familiarity with Django and likely have a local Django development project, and ...

Read more
Featured Image

Stockpile — Store Request and Response

One Piece — Whaaaat? You don’t use Stock Pile? For most applications, it is quite crucial to store the request and response of APIs, especially while integrating with external service providers. Logging this information solves for most of the use cases, but might not when the request/ response contains sensitive information. In such cases, one way would be to encrypt and store both the reque...

One Piece — Whaaaat? You don’t use Stock Pile? For most applications, it is quite crucial to store the request and response of APIs, especially while integrating with external service providers. Logging this information solves for most of the use cases, but might not when the request/ response ...

Read more
Featured Image

Avoid switch case for ENUMs – Visitor pattern

Don’t force-fit the switch-case (Spirited Away) Even before going ahead with an example, what is Visitor Pattern? Here is the Wikipedia definition. Let’s take a typical example for a Switch case for an ENUM: Consider the ENUM, Country: public enum Country { CHINA, INDIA, UNITED_STATES, BRAZIL, MEXICO, GERMANY } Write a function which takes the ENUM Country as the i...

Don’t force-fit the switch-case (Spirited Away) Even before going ahead with an example, what is Visitor Pattern? Here is the Wikipedia definition. Let’s take a typical example for a Switch case for an ENUM: Consider the ENUM, Country: public enum Country { CHINA, INDIA, UNITED_ST...

Read more