Mexico will deport about 500 migrants who on Sunday tried to “violently” and “illegally” cross the US border, the Mexican Interior Ministry in a statement quoted by Reuters.

The statement added that Mexican authorities had contained the protest at the crossing between Tijuana and San Diego.

It also said that, despite heightened tensions there, Mexico would not send military forces to control 7,417 migrants from a caravan currently amassed at the US-Mexico border.

Earlier on Sunday, US Customs and Border Protection closed road and pedestrian bridges in both directions at the San Ysidro port of entry.

The closures came after some 500 migrants overwhelmed federal and local Mexican police blockades and rushed toward the US border near Tijuana.

The Associated Press reported that the migrants were enveloped with tear gas after a few tried to breach the fence.

President Donald Trump has been seeking to block thousands of Central Americans who are making their way in caravans from entering the United States.

On Saturday, he reiterated on Twitter that he would not allow migrants to enter through the border with Mexico until their claims are examined by a court.

Trump took to Twitter again Sunday to express his displeasure with the caravans in Mexico.

“Would be very SMART if Mexico would stop the Caravans long before they get to our Southern Border, or if originating countries would not let them form (it is a way they get certain people out of their country and dump in U.S. No longer),” he wrote.