Baghdad, Iraq (CNN) When Iraq's parliament voted to expel American troops from the country Sunday, it was an apparent bid by the government to extract the country from an escalating US-Iran proxy war .

Fears of Iraq once again turning into a battleground are widespread. Tensions in the Middle Easthave risen dramatically in the aftermath of the US-targeted killing of Iran's most powerful military general, Qasem Soleimani , and Iraqi Shia paramilitary leader Abu Mahdi al-Muhandis.

Baghdad acted quickly. Caretaker Prime Minister Adil Abdul Mahdi held an emergency session in parliament to vote on whether the government should continue allowing the US military and other foreign troops to remain in the country. The resolution was passed overwhelmingly by Shia lawmakers (most members of Iraq's other factions sat out the vote), dealing potentially yet another blow to President Donald Trump's Middle East strategy.

"Iraqi priorities and the US are increasingly at odds," Abdul Mahdi said during his address to parliament.

He said a US troop withdrawal was the only way to "protect all those on Iraqi soil" -- especially American forces that require protection from the Iraqis.

"It would be difficult for Iraqi security forces to protect (US) forces after the recent events, given that unilateralism ... has won over political decision-making," the Prime Minister said.

In response, Trump has threatened to sanction Baghdad "like they've never seen before ever," if Iraq were to expel US troops.

"It'll make Iranian sanctions look somewhat tame," he added, a reference to over 1,000 rounds of economic penalties imposed by the US on Tehran after the Trump administration pulled out of the multilateral Iran nuclear deal in 2018.

Iraq was subjected to an international embargo after then President Saddam Hussein invaded Kuwait in 1990, leading to a humanitarian crisis that eased with the introduction of the United Nations' "Oil-for-Food Programme" that delivered supplies and equipment between 1996 and 2003.

What comes next

It is unclear what will happen next. Abdul Mahdi resigned in December after nationwide anti-government protests began. Iraq's current government and cabinet are just caretakers, and their powers are restricted to conducting the day-to-day affairs of the country.

The legal status of US troops in Iraq is also unclear. Typically, the Iraqi government would have the authority to cancel a security agreement with a foreign country. But due to its caretaker status, it has resorted to parliament.

The government now has a popular mandate to request that troops leave, but it is unclear if this is legally binding and no timetable was laid out in the resolution.

The resolution also does not enjoy the support of a large cross-section of Iraqi society. Most Sunni lawmakers and all Kurdish members of parliament sat out the session.

"(A US troop withdrawal) has ramifications for the Kurdistan region. It has ramifications for (predominantly Sunni) Anbar, and Mosul, and elsewhere where there could be a possible resurgence of ISIS," said Sajad Jiyad, managing director of al-Bayan Center, a Baghdad-based think tank.

Iraq has bilateral security agreements with the US and NATO, which came about as a result of the expansion of ISIS there. They were invited into the country in 2014 to counter the ISIS threat, and it's unclear how the resolution affects those accords.

But the coalition forces fighting ISIS have already announced that they would suspend operations against the extremist group, in order to focus on protecting Iraqi bases and coalition forces from Iranian-backed militias.

However, the growing calls for the departure of roughly 5,000 US troops may prove impossible to ignore.

Shia paramilitary leaders, an important political force in Iraq, are demanding the "immediate withdrawal" of US forces in the aftermath of Soleimani's killing. On Saturday and Sunday evening, rockets struck Baghdad's fortified Green Zone, which houses the US Embassy compound. No one has claimed responsibility for those attacks.

Iran and Tehran-backed Iraqi forces have vowed to avenge the deaths of the military leaders, and their rhetoric and threats were getting louder even before the vote in Iraq's parliament.

On Saturday evening, Shia paramilitary group Kataib Hezbollah, which was led by the slain al-Muhandis, warned that Iraqi security forces should stay outside a 1 kilometer (0.6 mile) radius of US bases. Hinting that US positions would become the target of attacks, the group warned Iraqi troops against becoming the "human shields" of foreign forces.

"If (US troops) don't leave, then they will be considered occupation forces," said Iran-backed paramilitary commander Qais Khazali on Sunday night.

The fiery Shia cleric called Trump's decision to carry out the strike that killed Soleimani the "most idiotic of all his crimes."

Jiyad, of the al-Bayan Center, said that by holding the vote on the resolution to remove US troops, "Abdul Mahdi was trying to get himself off the hook. He's saying the best way to de-escalate and not have further incidents is by saying 'US troops should leave.'"

JUST WATCHED How Soleimani used asymmetric warfare against Iran's enemies Replay More Videos ... MUST WATCH How Soleimani used asymmetric warfare against Iran's enemies 01:31

Region-wide ramifications

Elsewhere in the Middle East, anti-American political and military forces are hoping that other countries in the region follow suit. Hassan Nasrallah, head of the Iran-backed Lebanon-based militant and political group Hezbollah, endorsed Iraq's move to push out the US military.

Nasrallah, who has worked closely with Soleimani over the years, vowed to avenge the Iranian general's death by working to drive US forces from the region.

"The US military are the ones who killed (Soleimani and al-Muhandis) and they are the ones who will pay the price," said Nasrallah in a televised speech on Sunday.

Several countries across the region host US bases that house thousands of American troops. Many are afraid the current tensions could spiral into conflict and Gulf Arab countries are calling for de-escalation.

In Iraq, those who fear the consequences of a US withdrawal may be reluctant to take a public stance, according to Jiyad.

"At this moment in time, it's really difficult to come out and say 'we are pro-US, even though they've violated Iraq's sovereignty. Even though they've killed a senior member of Iraq's security forces, and they look like they're willing to do it again, we still want them to remain,'" Jiyad said.

"The fact is that the US was reckless and it put politicians who are pro-US in a difficult position where they can't come out and say 'we want the US to remain.'"