A former Army Ranger from San Antonio accused of supplying one of Mexico’s drug cartels with hundreds of high-powered firearms and tens of thousands of bullets will remain in jail.

U.S. Magistrate Judge Elizabeth “Betsy” Chestney denied a bid by Jose J. Soto Jr., 36, for bail after a lengthy hearing Wednesday. She found Soto not only posed a flight risk but is a danger to the public.

Soto joined the Army in 2004 and served 11 years, including with the elite special forces unit, until he was discharged honorably in 2015, his lawyer Scott McCrum said.

Federal authorities suspect Soto became a weapons supplier to the Cartel del Noreste, or CDN, a faction of the former Zetas.

“He’s an international arms dealer,” Assistant U.S. Attorney John Gibson told the judge. “He is basically an employee of the cartel.”

During the hearing, Homeland Security special agent Alfredo Martinez laid out much of the investigation that last week culminated with the arrest of Soto and three men from San Antonio suspected of involvement in a gun-trafficking ring: Derek Quintanilla, 28; Samuel Cardenas, 26; and Alex Bautista, 29.

Quintanilla was released on a signature bond Friday. Cardenas and Bautista reached an agreement with the government, before their bail hearings Wednesday, in which the feds no longer sought their detention, and were released later on signature bonds. As part of their conditions, they agreed to appear at future hearings in Corpus Christi, where all are charged with participating in a conspiracy to illegally export items on the munitions list and buying and selling guns without a license.

Cardenas’ lawyer said afterward that his client served in the Army for four years, primarily as a medic, and was honorably discharged.

Martinez testified that the group purchased at least 225 guns, AK and AR-style and .50-caliber rifles in a matter of months and got the bulk of them from Brian G. Morris of Yoakum, who also made some of them fully automatic, or turned them into machine guns. But Martinez also said the group got guns from sporting goods stores, at gun shows and other sources. The ring spent nearly $300,000 buying high-powered guns and tens of thousands of rifle magazines for them from those sources and online, Martinez testified.

He also said the cartel wanted the items because it was involved in turf wars with other cartels in Mexico.

Asked why the cartel wants so many magazines, Martinez said: “A lot of time they (cartel members) are involved in shootouts. They don’t have time to reload. They just change out magazines and the (empty) magazines are left at the scene.”

“We’re not talking .22-caliber (guns), it’s .50-caliber, assault rifles, grenade launchers,” Gibson said. “We’re talking weapons of war. There’s a war going on down there. ... It’s not a far leap to say people have died because of him.”

McCrum tried to minimize the allegations, or the reliability of government informants in the case.

He argued that Soto had legitimate reasons for taking so many trips to Laredo, and its neighbor south of the border, Nuevo Laredo, Mexico. Soto’s son from a previous relationship, McCrum said, lives in Laredo, as does his mom, who also owns a home in Nuevo Laredo. Soto’s wife is also from the Mexican border city and has family there.

His wife, Sara Elizabeth Soto, testified that her husband went to gun shows as part of a hobby, and that he was never violent with her or others.

But the judge seemed unconvinced.

“This is a lot — the quantity of the ammunition and guns,” Chestney said in denying Soto bond. “You can’t with a straight face make an argument that this is a collector or a hobbyist.”