Turkey's parliament approved a security and military deal with Libya's UN-supported government Saturday on the heels of a controversial maritime agreement earlier this month that has drawn international ire.
The deal allows Turkey to provide military training and equipment at the request of the Libyan government that controls the capital, Tripoli, and some of the country's west.
Forces loyal to a rival government based in Libya's east opened a fierce new assault on the capital last week and on Friday, they gave the militias defending Tripoli a three-day deadline to pull out.
The self-styled Libyan National Army, led by commander Khalifa Hifter, has been trying to capture the capital since April. The battle lines have barely changed in recent months.
Heavy fighting has threatened to plunge the North African nation into another bout of violence rivaling the scale of the 2011 conflict, which ousted and killed longtime dictator Moammar Gadhafi.
The UN has criticized foreign interference in Libya amid the recent escalation in violence, and urged Libyans to return to political dialogue.
UN experts have also identified multiple cases of non-compliance with a UN arms embargo. They said the majority of transfers sent to Hifter's LNA were from Jordan or the United Arab Emirates, while the majority of arms sent to the Tripoli government came from Turkey.
Turkish President Recep Tayyip Erdogan signed the two agreements with Tripoli in November. He said Turkey could deploy troops to Libya upon request.
Turkish lawmakers now have given the green light to send military advisors , experts and personnel to the conflict, if asked. Ankara could also send weapons and military vehicles, conduct military training, joint exercises and share intelligence.
The separate maritime boundary agreement, signed into law earlier this month, could give Turkey access to a contested economic zone across the eastern Mediterranean Sea.
The deal has added tension to Turkey's ongoing dispute with Greece, Cyprus and Egypt over oil and gas drilling rights in the eastern Mediterranean.
Speaking before the vote, parliamentarians from the ruling party argued the deal would aid the "legitimate government" in Tripoli, ensuring Libya's stability and Turkey's interests in the eastern Mediterranean.
Opposition Republican People's Party legislator Unal Cevikoz said the agreement amounted to meddling in Libya's internal affairs, violating a UN arms embargo and further destabilizing the country by "adding fuel to fire in Libya." He said the deal was against Turkey's interests and created the possibility of putting Turkish troops at risk.
"Do you want to protect the interests of our country? Then don't be party to the war in Libya. Don't send weapons and fighters to Libya," Cevikoz said.
Besides Turkey, the Tripoli-based government is by backed Italy and Qatar.
The eastern government is supported by France Russia, Jordan, the UAE and other key Arab countries.
Libyan and US officials have accused Russia of deploying fighters through a private security contractor, the Wagner Group, to fight alongside with Hifter's forces. Moscow has repeatedly denied any role in the fighting.