KASTANIES, Greece (Reuters) - Greek police fired teargas toward migrants who were gathered on its border with Turkey and demanding entry on Saturday, as a crisis over Syria abruptly moved onto the European Union’s doorstep.

Slideshow ( 3 images )

The Greek government reiterated its promise to keep migrants out.

“The government will do whatever it takes to protect its borders,” government spokesman Stelios Petsas told reporters, adding that in the past 24 hours Greek authorities had averted attempts by 4,000 people to cross.

Live images from Greece’s Skai TV on the Turkish side of the northern land border at Kastanies showed Greek riot police firing teargas rounds at groups of migrants who were hurling stones and shouting obscenities.

Media were not permitted to approach the Greek side of the border in the early morning, but the area smelled heavily of teargas, a Reuters witness said.

A Turkish government official said late Thursday that Turkey will no longer contain the hundreds of thousands of asylum seekers after an air strike on war-ravaged Idlib in Syria killed 33 Turkish soldiers earlier that day.

Almost immediately, convoys of people appeared heading to the Greek land and sea borders on Friday.

An estimated 3,000 people had gathered on the Turkish side of the border at Kastanies, according to a Greek government official. Kastanies lies just over 900 km (550 miles)north-east of Athens.

Greece, which was a primary gateway for hundreds of thousands of asylum seekers in 2015 and 2016, has promised it will keep the migrants out.

However, Turkish President Tayyip Erdogan said on Saturday that some 18,000 migrants had crossed borders from Turkey into Europe. Speaking in Istanbul, he did not immediately provide evidence for the number, but said it would rise.

Greek police were keeping media about a kilometer away from the Kastanies border crossing, but the broader area, where the two countries are divided by a river, was more permeable.

A group of Afghans with young children waded across fast-moving waters of the Evros river and took refuge in a small chapel. They crossed into Greece on Friday morning.

“Today is good” said Shir Agha, 30 in broken English. “Before, Erdogan people, police problem,” he said. Their shoes were caked in mud. It had rained heavily the night before, and by early morning, temperatures were close to freezing.

Greece had already said on Thursday it would tighten border controls to prevent coronavirus reaching its Aegean islands, where thousands of migrants are living in poor conditions.

Nearly a million refugees and migrants crossed from Turkey to Greece’s islands in 2015, setting off a crisis over immigration in Europe, but that route all but closed after the European Union and Ankara agreed to stop the flow in March 2016.