How to resize an LVM ext4 partition (and also non-LVM because old VMs)

what & why Every now and then, I have to resize a root partition on an LVM linux machine. Every time, I take more time to recall what steps to do, and in which order. Is it pvresize, then lvrezise, or lvextend ? Every. god. damn. time. Let’s put an end to this by having the steps written down somewhere, so I can reference them when the ‘we should increase this vm’s disk’ sentence is heard. ...

April 29, 2024 · 9 min · 1770 words

Remote layer cache for multiple docker CI runners

what and why At $job, we are using jenkins with a dozen or so docker runners, each running their own docker daemon. At least a few hundred builds are carried out daily on these runners, mainly producing docker images that are then pushed onto a testing/production container registry. But two jobs from the same repo might not be using the same CI runner (most of the time they are not). It means each docker runner might need to rebuild the first couple of layers from a given Dockerfile, despite another worker having already built the same layers a few hours/minutes ago. That’s wasting CPU cycles, bandwith, and it’s also increasing the time each build is taking. ...

February 19, 2024 · 10 min · 2083 words

Reset a lost account password using docker

Story time A funny thing happened today. A remote Raspberry Pi deployed a few years back for $client was having issues connecting with another system. When setting up the Pi, I thought of sharing my ssh key from my laptop so I could SSH into it passwordless-style. But it didn’t occured to younger (and stupider apparently) me to save the password for that account somewhere. And on that system (and generally on Debian I believe), standard accounts are in the sudo group, but not with passwordless access, meaning you can run sudo but you have to enter your session’s password. ...

August 9, 2023 · 3 min · 498 words