-
My New Favourite Editor is Neither VS Code Nor Atom
I used to use Atom as my main editor but it somehow lost its popularity and withered sadly. Then I switched to VS Code which is also Electron based and similar to Atom in some ways. VSC was great until recently I heard about Zed, which I immediately felt excited about it, for a few…
-
A Simple and Interactive Decoder for Kubernetes Secrets
TL; DR: Here’s a simple shell function which can decode Kubernetes secrets interactively and should work in any Bash and compatible environments. Requirements: Here’s the code. This can be chained together with other commands too, eg. on a Mac, I can do Then the decoded content of selected secret key will be put into clipboard.…
-
How to Use the Sidecar Resource to Optimise Memory Footprint of Istio Sidecar
In a populous GKE cluster, I saw the memory utilisation getting very high. After some investigation, to my surprise, a great deal of memory was consumed by tiny Istio sidecars. And they are getting bloated round the clock. The Istio sidecar essentially is an envoy proxy configured by Istio controller – istiod. It’s usually light-weight,…
-
An Admin-Only Python Decorator for Telegram Bots
TL; DR: Here’s a Python Decorator I wrote for Telegram Bots so certain commands can only be used by group admins.
-
Solved: Blank Screen After Login in Gnome Shell 44
Background: I have an old desktop computer running Fedora 36 + Gnome Shell desktop environment and upgraded to 38 recently. It was used as an archive so I left it in garage and only connect to it vis SSH or VNC. Now I moved it into my home office because I think it can act…
-
How to Sort Lines in YAML
I asked myself this question and it turns out that I don’t need to write a script to do this, yq has the answer already. More on array sorting and map sorting 🙂
-
SAUS: Such A URL Shortener
TL; DR: It’s a simple but effective URL shortener I wrote in Python + Django, I consider it stable now. Also added QR code generator for mobile applications. Source code is in Github. 🙂
-
How to Serve QR Images from Memory with Django
TL; DR: I used SpooledTemporaryFile with FileResponse to server generated QR images directly from memory, no disk IO involved. Please see my code sample with notes: 🙂