COLOMBO - Sri Lanka’s outgoing Prime Minister Mahinda Rajapaksa was rescued in a pre-dawn military operation Tuesday, hours after his resignation, as violent clashes between pro and anti-government protesters left several dead and 217 injured.

The military were called to the Prime Minister’s ‘Temple Trees’ compound after protesters tried to breach his private residence twice overnight, a senior security source told CNN.

The attackers managed to “enter the outer perimeter” of the residence where they hurled petrol bombs, but their attempts to enter the building were thwarted when the military fired tear gas, according to the source.

One police officer involved in the clashes died at the scene when a tear gas gun exploded, the security official said, confirming that Prime Minister Rajapaksa and his family have since been taken to an undisclosed location.

A Sri Lankan man protects his eyes from tear gas as he passes the site of anti-government protests in Colombo on May 9. The scenes followed an evening of violent clashes across Sri Lanka’s capital Colombo on Monday, during which at least seven people died according to police, although it is unclear if all of the deaths were directly related to the protests.

Some 217 people were also injured as a result of the clashes, local health authorities reported. Prime Minister Mahinda Rajapaksa quit on Monday evening shortly after a nationwide curfew was imposed. The curfew came after live television showed footage of government supporters, armed with sticks, beating protesters at several locations across the capital, including at Galle Face Green park, and tearing down and burning their tents. Dozens of homes were torched across the country amid the violence, according to witnesses CNN spoke to.

The park has become a focal point for protesters who have been demonstrating for weeks against the government’s alleged mishandling of an economic crisis that has caused prices of everyday goods to soar and widespread electricity shortages.

Armed troops were deployed, according to CNN’s team on the ground, while video footage showed police firing tear gas and water cannons to disperse the protesters.

“We are helpless now, we are begging for help,” Pasindu Senanayaka, an anti-government protestor told Reuters, as black smoke spiraled out of a burning tent nearby and parts of the protest camp lay in disarray. Police have accused the protesters of violence too, saying they attacked buses carrying local officials to Colombo for a meeting with the Prime Minister. Following the chaotic scenes, the government brought in an island-wide curfew, and soon afterwards the Prime Minister, 76, resigned. “Multiple stakeholders have indicated the best solution to the present crisis is the formation of an interim all-party government,” he said.

“Therefore, I have tendered my resignation so the next steps can be taken in accordance with the Constitution.”

However, it remains unclear if the curfew and his resignation will be enough to keep a lid on the increasingly volatile situation in the country of 22 million.

| Troops deployed, while police firing tear gas and water cannons to disperse protesters