Connecting driving/brake lights to rover via ESC or Pixhawk

Hello

I have built a Rover and what to connect driving lights and brake lights, that work when it is braking or reversing. I am using a Pixhawk 6C and two dual Flipsky ESC.

Does anyone have any tips on this?

Thank you in advance.