How to safely discharge oneself
The best way is to use an ESD strap, that is connected to earth via a 1MOhm resistor. This slowly but continuously discharges you without creating high currents. This way it does not hurt or damage anything.

But I also want to mention one "trick", when you dont want to use special equipment like an ESD strap. Discharging at the earth connection of mains works quite well, when you do not touch the contact directly but via an object you are holding in your hand (and that is at least slightly conductiv). I always get a big discharge when touching doorknobs at work, so I started to first touch the knob with my watch. This way the spark only exists between watch an knob, the current densitiy in my arm is already so low that I do not feel it any more. Or when getting out of car I already have the key in my hand - so I touch the door with the key first, before touching the metal directly.

But still - if your are regularyly working with electronics on your desk some basic ESD equipment would be the best solution. And I guess your boss will agree that the cost of an ESD strap is neglectable im comparison to failing electronics ;)