Or you build bunkers and build robots to keep the riffraff out. Shock collars on the guards' necks.
https://www.theguardian.com/news/2022/sep/04/super-rich-prep...
> The billionaires considered using special combination locks on the food supply that only they knew. Or making guards wear disciplinary collars of some kind in return for their survival. Or maybe building robots to serve as guards and workers – if that technology could be developed “in time”.