Printing a part from plastic can work but its not something I'd use a structural component. Instead I'd look at folding something up out of strip steel or aluminium.
Head lamps are good in that they follow your face-direction. So you can aim them at something.
Bar lamps are good because they light up where your wheel is about to roll.
Personally I run both head and bar lights for these reasons. Batteries are cheap, recharging is easy, and problem avoidance is a good idea.
Do explore the legal allowances in your area - here in NZ we're allowed up to two lights on the bars, only one of which may blink. Personally I have exactly that, plus one on the fork and two on the helmet. I choose to consciously have more lights than permitted - you make your own choice.