I use petrol-gel for various homebrewing tasks, mostly lubing up o-rings. I’ve had this tube for many years and the cap broke for who knows what reason. Not everything needs to be a complex repair.

I measured the outer diameter of the original cap and the outer diameter of the tube threads. Then I designed a simple cylinder just slightly smaller than the tube threads, hoping the tube would self-thread when I screwed the cap on. Amazingly, it worked great.

CAD render of the cap design in Onshape It’s just a cylinder

3D printed red cap on a Petrol-Gel lubricant tube Replacement cap on the tube