I read this story around 40 years ago in the late 70s, though I think the anthology it was in was already at least 10 years old at the time. The story (in my memory) seems much more like a golden-age story than something that would have been written more contemporaneously.
The story is set on a planetoid or asteroid with a mining base (I recall the population being overwhelmingly, if not entirely, male) that is attacked and taken over by a hostile force. (They may not have been precisely pirates, but a hostile military force attacking a civilian base is pretty close to that.) The miners are herded into a pit (the mine?) with the pirates placing ray gun emplacements around it to keep them under threat. I do not recall what the pirates were after; it may be that the miners were only hostages.
It turns out the ore in the pit can reflect the rays from the pirates' guns, so after some surreptitious preparation the miners attack the pirates, reflecting their own guns back at them.
In my recollection, the miners were described as "dancing" as they dodged and reflected the rays.
(In retrospect, those were some pretty stupid pirates.)