Translation:A holder for a candle is a candle holder.
Indeed, it has both meaning. ReVo ( http://www.reta-vortaro.de/cgi-bin/sercxu.pl?sercxata=ingokadroj=1 ) gives this definition: Objekto, kiu servas por surkovri, ŝirmi alian objekton parte enigitan en ĝi (object which is used to cover, shelter, … another object partly plugged in it).
In general, Esperanto compounding words (all these two or three letters words whose goal is clearly to be used compounded with others) are quite vague in meaning: it’s their attached word which gives most of it ☺
Technically, a light socket is not a socket for light, but for a light bulb. Personally, I would like to think that Esperanto employs a more direct, less idiomatic approach, and translates it accordingly as "ampolingo", rather than "lumingo", and I think "ampolingo" is indeed the common term.