For non-oversized handlebars (25.4mm or 26.0mm), you can also use a Wald #40 steel flashlight holder if you want to be all retro and stuff

A layer or two of inner tube over the barrel of the light may be needed to eliminate rattling.
http://www.amazon.com/Wald-Flashligh.../dp/B000AO3H24