Computer lights are designed to operate on 5 or 12V DC.
Your mains supply (depending on where you live) will be 230V (europe) or 120V (USA) AC.
Essentially this means that you would require some type of AC-DC convertor with the ability to step down the output voltage to 5 or 12V.
These may come with various jacks to fit different appliances but you can cut the jack off & wire a molex connector on the end instead, so you can plug a light straight into it.
NB If you are planning to connect more than one light to the adapter, make sure they are connected in parallel otherwise you'll split the supply voltage & they won't all work.