If your limit switches are mechanical, then maybe you can activate a digital filter in the controller to prevent reacting on glitches.
I use proximity switches, cheap ebay versions. They are not sensitive to vibration but to electric interference. They worked flawless on the mini lathe, but couldn't get them working on the small lathe. Every time I switched on/off the small lathe motor, the sensor tripped. The final solution was to activate debouncing in the controller. Now they work very well and reliable.
proximity switches I use:
NJK-5002C, NJK-5001C, LJ12A3-4-Z, TL-W5MC1