I loved the idea of the heatshrink, but couldn’t be bothered. I loved the idea of the 3D-printed bracket, but still couldn’t be bothered.
So…
I stole some foam from my kids’ craft supplies and cut it into strips. Not as clever, I’ll admit, but better than nothing - and took a couple of minutes, tops. I’ve checked, and they seem to stay in place nicely - though if I were buying foam specifically for the job I’d maybe have picked some a millimetre or two thicker.