If you want to keep it really cheap you could take the PCB out of some broken electronics, find a section that’s mostly unpopulated, cut an appropriately sized disc, solder the spring to it, dab of glue, and stick it in the tailcap.
As long as there are no throughs on the section it will be isolated from the tailcap and give you trouble-free lockout.
Barely chamfer the copper side to isolate it from any exposed aluminum.