Sometimes, mostly when throwing together a quick idea or MVP, it can be useful to just register all models with the admin and leave proper customization for later.[Read More]
Add fields to list with Kustomize
How to add things to a list using kustomize. This is useful for example when you need to patch additional environment variables into a pod.[Read More]
Copy & Paste Is Dangerous
Copy & paste from untrusted sources on the internet into the terminal is a really bad idea! Early in my career I did it too and still often see others doing it.[Read More]
Render Plain HTML with Hugo
Hugo is my favorite tool for publishing markdown to the internet, but sometimes I want to do something a little bit more advanced with my posts.
With this shortcode I can always just fall back to plain old HTML.[Read More]
Hugo Details Shortcode
Ansible and cowsay
Cowsay is one of those packages you just end up installing randomly on just about any client over time.
And if your using ansible you may be in for a little surprise:[Read More]
Django: CSRF exempt view
Django’s CSRF protection is usually a great thing, but when building (API) endpoints meant to be accessed by scripts/third parties it gets in the way of that.
This is how to disable it:
For a class based view
from django.utils.decorators import method_decorator from django.views.decorators.csrf import csrf_exempt @method_decorator(csrf_exempt, name='dispatch') class MyView(View): pass
For a function based view
from django.views.decorators.csrf import csrf_exempt @csrf_exempt def my_view(request): pass
My Publishing Pipeline
I write an extensive personal knowledge base using markdown, code-server and a variety of other tools. Originally, in 2021, I wanted to have something like Obsidian Publish but self-hosted, so I created it.
Over time my knowledge base evolved more into a second brain, tracking not only my technical notes and journal, but also things like recipes and hikes. With this my publishing pipeline, and the script at it’s core, extended in a multitude of ways.[Read More]