A gunman wearing a makeshift suicide vest screamed "Allahu Akbar" as he opened fire in a Spanish supermarket.

The attacker, reportedly carrying gasoline and gunpowder in his pockets, walked into the Mercadona shop, in the As Lagoas district of Ourense, before firing shots into the air.

GREEK OFFICIALS LINK GUN FIRED AT POLICE WITH FAR LEFTISTS

Several shoppers were inside the supermarket when the man entered and fired several shots into the air – alerting emergency services to the attack.

Armed police then reportedly led the gunman out of the shop, telling passers-by to stand back.

The incident, which happened at around 2pm, did not result in any injuries but left shoppers extremely shaken.

According to Spanish media outlet La Region, police officer Carlos Perez, 38, revealed the gunman fired at him and he had to wait for backup.

He and his colleagues were able to detain him after he ran out of ammunition.

This story first appeared in The Sun.