So, you need a common earth from the bulb holder to the frame( assuming its a -ve frame) then, depending on the bulb type, you will need one wire back to a switched +ve from the headlight switch, plus a wire back to the pressure brake switch from a +ve feed.
Effectively, it's one bulb with two circuits, with two switches through a common earth. When either switch is activated, you get the correct filament illuminating. It's always worth checking on the bench with a test battery to establish which connection is associated with each filament.
Hope this helps