use an L bracket bolted to the cassette.
Matt is right. Make one. But Comet does sell one, https://cometkartsales.com/Mychron-Axle-Speed-Sensor-Bracket.html
CAPTCHA Code