Sometimes you have a tricky situation where you can deploy a Django application but have little control over the front end web server or load balancer terminating your SSL. The code snippet below is an easy way to issue a 301 redirect for any http request. It will also remove the www prefix.

Replace YOUR_DJANGO_SETTINGS.settings with your settings.

A secure Kubernetes deployment benefits from Kubernetes specific security tools. One high quality open source tool is Falco. Falco is an intrusion detection system that reports suspicious Kubernetes events that a security admin might want to know about. This is an IDS, so it can be chatty. I found that it will report lots of less than useful system call event drops. You can easily opt to log and not notify you about these events, which is what I am choosing to do for now.

Here is a quick guide to deploying Falco on Kubernetes

This app will run as a daemon set and require about 1 GB of memory per node.

Image for post
Image for post

Deploying Kubernetes on premises can be challenging enough.

You’ll quickly find out things you’d expect to work, simply don’t. That’s because cloud providers do lots of things for you (which is good).

I am currently storing docker images on ECR (AWS elastic container registry). It’s easy to use some simple commands to authenticate with your configured credentials then push / pull images when developing.

But this is something you are going to want to just do with Kubernetes. It is also essential for Kubernetes to be able to pull images from the cloud when it needs to. …

Get the Medium app

A button that says 'Download on the App Store', and if clicked it will lead you to the iOS App store
A button that says 'Get it on, Google Play', and if clicked it will lead you to the Google Play store